OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 289 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
300 void Generate(MacroAssembler* masm); | 300 void Generate(MacroAssembler* masm); |
301 | 301 |
302 private: | 302 private: |
303 Major MajorKey() { return ToNumber; } | 303 Major MajorKey() { return ToNumber; } |
304 int MinorKey() { return 0; } | 304 int MinorKey() { return 0; } |
305 }; | 305 }; |
306 | 306 |
307 | 307 |
308 class FastNewClosureStub : public CodeStub { | 308 class FastNewClosureStub : public CodeStub { |
309 public: | 309 public: |
310 explicit FastNewClosureStub(StrictModeFlag strict_mode) | 310 explicit FastNewClosureStub(LanguageMode language_mode) |
311 : strict_mode_(strict_mode) { } | 311 : language_mode_(language_mode) { } |
312 | 312 |
313 void Generate(MacroAssembler* masm); | 313 void Generate(MacroAssembler* masm); |
314 | 314 |
315 private: | 315 private: |
316 Major MajorKey() { return FastNewClosure; } | 316 Major MajorKey() { return FastNewClosure; } |
317 int MinorKey() { return strict_mode_; } | 317 int MinorKey() { return language_mode_ == CLASSIC_MODE |
| 318 ? kNonStrictMode : kStrictMode; } |
318 | 319 |
319 StrictModeFlag strict_mode_; | 320 LanguageMode language_mode_; |
320 }; | 321 }; |
321 | 322 |
322 | 323 |
323 class FastNewContextStub : public CodeStub { | 324 class FastNewContextStub : public CodeStub { |
324 public: | 325 public: |
325 static const int kMaximumSlots = 64; | 326 static const int kMaximumSlots = 64; |
326 | 327 |
327 explicit FastNewContextStub(int slots) : slots_(slots) { | 328 explicit FastNewContextStub(int slots) : slots_(slots) { |
328 ASSERT(slots_ > 0 && slots_ <= kMaximumSlots); | 329 ASSERT(slots_ > 0 && slots_ <= kMaximumSlots); |
329 } | 330 } |
(...skipping 743 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1073 int MinorKey() { return 0; } | 1074 int MinorKey() { return 0; } |
1074 | 1075 |
1075 void Generate(MacroAssembler* masm); | 1076 void Generate(MacroAssembler* masm); |
1076 | 1077 |
1077 DISALLOW_COPY_AND_ASSIGN(StoreArrayLiteralElementStub); | 1078 DISALLOW_COPY_AND_ASSIGN(StoreArrayLiteralElementStub); |
1078 }; | 1079 }; |
1079 | 1080 |
1080 } } // namespace v8::internal | 1081 } } // namespace v8::internal |
1081 | 1082 |
1082 #endif // V8_CODE_STUBS_H_ | 1083 #endif // V8_CODE_STUBS_H_ |
OLD | NEW |