OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef V8_BUILTINS_BUILTINS_H_ | 5 #ifndef V8_BUILTINS_BUILTINS_H_ |
6 #define V8_BUILTINS_BUILTINS_H_ | 6 #define V8_BUILTINS_BUILTINS_H_ |
7 | 7 |
8 #include "src/base/flags.h" | 8 #include "src/base/flags.h" |
9 #include "src/handles.h" | 9 #include "src/handles.h" |
10 | 10 |
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
137 API(HandleApiCallAsFunction) \ | 137 API(HandleApiCallAsFunction) \ |
138 API(HandleApiCallAsConstructor) \ | 138 API(HandleApiCallAsConstructor) \ |
139 ASM(HandleFastApiCall) \ | 139 ASM(HandleFastApiCall) \ |
140 /* Adapters for Turbofan into runtime */ \ | 140 /* Adapters for Turbofan into runtime */ \ |
141 ASM(AllocateInNewSpace) \ | 141 ASM(AllocateInNewSpace) \ |
142 ASM(AllocateInOldSpace) \ | 142 ASM(AllocateInOldSpace) \ |
143 /* Debugger */ \ | 143 /* Debugger */ \ |
144 DBG(Return_DebugBreak) \ | 144 DBG(Return_DebugBreak) \ |
145 DBG(Slot_DebugBreak) \ | 145 DBG(Slot_DebugBreak) \ |
146 DBG(FrameDropper_LiveEdit) \ | 146 DBG(FrameDropper_LiveEdit) \ |
147 /* Primitives */ \ | 147 /* Type conversions */ \ |
148 ASM(StringToNumber) \ | |
149 ASM(NonNumberToNumber) \ | |
150 ASM(ToNumber) \ | |
151 TFS(OrdinaryToPrimitive_Number, BUILTIN, kNoExtraICState, TypeConversion) \ | 148 TFS(OrdinaryToPrimitive_Number, BUILTIN, kNoExtraICState, TypeConversion) \ |
152 TFS(OrdinaryToPrimitive_String, BUILTIN, kNoExtraICState, TypeConversion) \ | 149 TFS(OrdinaryToPrimitive_String, BUILTIN, kNoExtraICState, TypeConversion) \ |
153 TFS(NonPrimitiveToPrimitive_Default, BUILTIN, kNoExtraICState, \ | 150 TFS(NonPrimitiveToPrimitive_Default, BUILTIN, kNoExtraICState, \ |
154 TypeConversion) \ | 151 TypeConversion) \ |
155 TFS(NonPrimitiveToPrimitive_Number, BUILTIN, kNoExtraICState, \ | 152 TFS(NonPrimitiveToPrimitive_Number, BUILTIN, kNoExtraICState, \ |
156 TypeConversion) \ | 153 TypeConversion) \ |
157 TFS(NonPrimitiveToPrimitive_String, BUILTIN, kNoExtraICState, \ | 154 TFS(NonPrimitiveToPrimitive_String, BUILTIN, kNoExtraICState, \ |
158 TypeConversion) \ | 155 TypeConversion) \ |
| 156 ASM(StringToNumber) \ |
| 157 TFS(NonNumberToNumber, BUILTIN, kNoExtraICState, TypeConversion) \ |
| 158 ASM(ToNumber) \ |
159 \ | 159 \ |
160 /* Built-in functions for Javascript */ \ | 160 /* Built-in functions for Javascript */ \ |
161 /* Special internal builtins */ \ | 161 /* Special internal builtins */ \ |
162 CPP(EmptyFunction) \ | 162 CPP(EmptyFunction) \ |
163 CPP(Illegal) \ | 163 CPP(Illegal) \ |
164 CPP(RestrictedFunctionPropertiesThrower) \ | 164 CPP(RestrictedFunctionPropertiesThrower) \ |
165 CPP(RestrictedStrictArgumentsPropertiesThrower) \ | 165 CPP(RestrictedStrictArgumentsPropertiesThrower) \ |
166 /* Array */ \ | 166 /* Array */ \ |
167 ASM(ArrayCode) \ | 167 ASM(ArrayCode) \ |
168 ASM(InternalArrayCode) \ | 168 ASM(InternalArrayCode) \ |
(...skipping 339 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
508 static void Generate_JSEntryTrampoline(MacroAssembler* masm); | 508 static void Generate_JSEntryTrampoline(MacroAssembler* masm); |
509 static void Generate_JSConstructEntryTrampoline(MacroAssembler* masm); | 509 static void Generate_JSConstructEntryTrampoline(MacroAssembler* masm); |
510 static void Generate_ResumeGeneratorTrampoline(MacroAssembler* masm); | 510 static void Generate_ResumeGeneratorTrampoline(MacroAssembler* masm); |
511 static void Generate_NotifyDeoptimized(MacroAssembler* masm); | 511 static void Generate_NotifyDeoptimized(MacroAssembler* masm); |
512 static void Generate_NotifySoftDeoptimized(MacroAssembler* masm); | 512 static void Generate_NotifySoftDeoptimized(MacroAssembler* masm); |
513 static void Generate_NotifyLazyDeoptimized(MacroAssembler* masm); | 513 static void Generate_NotifyLazyDeoptimized(MacroAssembler* masm); |
514 static void Generate_NotifyStubFailure(MacroAssembler* masm); | 514 static void Generate_NotifyStubFailure(MacroAssembler* masm); |
515 static void Generate_NotifyStubFailureSaveDoubles(MacroAssembler* masm); | 515 static void Generate_NotifyStubFailureSaveDoubles(MacroAssembler* masm); |
516 static void Generate_ArgumentsAdaptorTrampoline(MacroAssembler* masm); | 516 static void Generate_ArgumentsAdaptorTrampoline(MacroAssembler* masm); |
517 static void Generate_StringToNumber(MacroAssembler* masm); | 517 static void Generate_StringToNumber(MacroAssembler* masm); |
518 static void Generate_NonNumberToNumber(MacroAssembler* masm); | |
519 static void Generate_ToNumber(MacroAssembler* masm); | 518 static void Generate_ToNumber(MacroAssembler* masm); |
520 | 519 |
521 static void Generate_Apply(MacroAssembler* masm); | 520 static void Generate_Apply(MacroAssembler* masm); |
522 | 521 |
523 // ES6 section 9.2.1 [[Call]] ( thisArgument, argumentsList) | 522 // ES6 section 9.2.1 [[Call]] ( thisArgument, argumentsList) |
524 static void Generate_CallFunction(MacroAssembler* masm, | 523 static void Generate_CallFunction(MacroAssembler* masm, |
525 ConvertReceiverMode mode, | 524 ConvertReceiverMode mode, |
526 TailCallMode tail_call_mode); | 525 TailCallMode tail_call_mode); |
527 static void Generate_CallFunction_ReceiverIsNullOrUndefined( | 526 static void Generate_CallFunction_ReceiverIsNullOrUndefined( |
528 MacroAssembler* masm) { | 527 MacroAssembler* masm) { |
(...skipping 302 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
831 friend class BuiltinFunctionTable; | 830 friend class BuiltinFunctionTable; |
832 friend class Isolate; | 831 friend class Isolate; |
833 | 832 |
834 DISALLOW_COPY_AND_ASSIGN(Builtins); | 833 DISALLOW_COPY_AND_ASSIGN(Builtins); |
835 }; | 834 }; |
836 | 835 |
837 } // namespace internal | 836 } // namespace internal |
838 } // namespace v8 | 837 } // namespace v8 |
839 | 838 |
840 #endif // V8_BUILTINS_BUILTINS_H_ | 839 #endif // V8_BUILTINS_BUILTINS_H_ |
OLD | NEW |