Reviewed by Cameron Zwarich.
- always use CTI_ARGUMENTS and CTI_ARGUMENTS_FASTCALL
This is a small regression for GCC 4.0, but simplifies the code
for future improvements and lets us focus on GCC 4.2+ and MSVC.
* VM/CTI.cpp:
* VM/CTI.h:
* VM/Machine.cpp:
(JSC::Machine::cti_op_convert_this):
(JSC::Machine::cti_op_end):
(JSC::Machine::cti_op_add):
(JSC::Machine::cti_op_pre_inc):
(JSC::Machine::cti_timeout_check):
(JSC::Machine::cti_register_file_check):
(JSC::Machine::cti_op_loop_if_less):
(JSC::Machine::cti_op_loop_if_lesseq):
(JSC::Machine::cti_op_new_object):
(JSC::Machine::cti_op_put_by_id):
(JSC::Machine::cti_op_put_by_id_second):
(JSC::Machine::cti_op_put_by_id_generic):
(JSC::Machine::cti_op_put_by_id_fail):
(JSC::Machine::cti_op_get_by_id):
(JSC::Machine::cti_op_get_by_id_second):
(JSC::Machine::cti_op_get_by_id_generic):
(JSC::Machine::cti_op_get_by_id_fail):
(JSC::Machine::cti_op_instanceof):
(JSC::Machine::cti_op_del_by_id):
(JSC::Machine::cti_op_mul):
(JSC::Machine::cti_op_new_func):
(JSC::Machine::cti_op_call_JSFunction):
(JSC::Machine::cti_vm_compile):
(JSC::Machine::cti_op_push_activation):
(JSC::Machine::cti_op_call_NotJSFunction):
(JSC::Machine::cti_op_create_arguments):
(JSC::Machine::cti_op_tear_off_activation):
(JSC::Machine::cti_op_tear_off_arguments):
(JSC::Machine::cti_op_ret_profiler):
(JSC::Machine::cti_op_ret_scopeChain):
(JSC::Machine::cti_op_new_array):
(JSC::Machine::cti_op_resolve):
(JSC::Machine::cti_op_construct_JSConstruct):
(JSC::Machine::cti_op_construct_NotJSConstruct):
(JSC::Machine::cti_op_get_by_val):
(JSC::Machine::cti_op_resolve_func):
(JSC::Machine::cti_op_sub):
(JSC::Machine::cti_op_put_by_val):
(JSC::Machine::cti_op_put_by_val_array):
(JSC::Machine::cti_op_lesseq):
(JSC::Machine::cti_op_loop_if_true):
(JSC::Machine::cti_op_negate):
(JSC::Machine::cti_op_resolve_base):
(JSC::Machine::cti_op_resolve_skip):
(JSC::Machine::cti_op_resolve_global):
(JSC::Machine::cti_op_div):
(JSC::Machine::cti_op_pre_dec):
(JSC::Machine::cti_op_jless):
(JSC::Machine::cti_op_not):
(JSC::Machine::cti_op_jtrue):
(JSC::Machine::cti_op_post_inc):
(JSC::Machine::cti_op_eq):
(JSC::Machine::cti_op_lshift):
(JSC::Machine::cti_op_bitand):
(JSC::Machine::cti_op_rshift):
(JSC::Machine::cti_op_bitnot):
(JSC::Machine::cti_op_resolve_with_base):
(JSC::Machine::cti_op_new_func_exp):
(JSC::Machine::cti_op_mod):
(JSC::Machine::cti_op_less):
(JSC::Machine::cti_op_neq):
(JSC::Machine::cti_op_post_dec):
(JSC::Machine::cti_op_urshift):
(JSC::Machine::cti_op_bitxor):
(JSC::Machine::cti_op_new_regexp):
(JSC::Machine::cti_op_bitor):
(JSC::Machine::cti_op_call_eval):
(JSC::Machine::cti_op_throw):
(JSC::Machine::cti_op_get_pnames):
(JSC::Machine::cti_op_next_pname):
(JSC::Machine::cti_op_push_scope):
(JSC::Machine::cti_op_pop_scope):
(JSC::Machine::cti_op_typeof):
(JSC::Machine::cti_op_is_undefined):
(JSC::Machine::cti_op_is_boolean):
(JSC::Machine::cti_op_is_number):
(JSC::Machine::cti_op_is_string):
(JSC::Machine::cti_op_is_object):
(JSC::Machine::cti_op_is_function):
(JSC::Machine::cti_op_stricteq):
(JSC::Machine::cti_op_nstricteq):
(JSC::Machine::cti_op_to_jsnumber):
(JSC::Machine::cti_op_in):
(JSC::Machine::cti_op_push_new_scope):
(JSC::Machine::cti_op_jmp_scopes):
(JSC::Machine::cti_op_put_by_index):
(JSC::Machine::cti_op_switch_imm):
(JSC::Machine::cti_op_switch_char):
(JSC::Machine::cti_op_switch_string):
(JSC::Machine::cti_op_del_by_val):
(JSC::Machine::cti_op_put_getter):
(JSC::Machine::cti_op_put_setter):
(JSC::Machine::cti_op_new_error):
(JSC::Machine::cti_op_debug):
(JSC::Machine::cti_vm_throw):
* VM/Machine.h:
* masm/X86Assembler.h:
(JSC::X86Assembler::emitRestoreArgumentReference):
(JSC::X86Assembler::emitRestoreArgumentReferenceForTrampoline):
* wtf/Platform.h:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@37581
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2008-10-14 Maciej Stachowiak <mjs@apple.com>
+
+ Reviewed by Cameron Zwarich.
+
+ - always use CTI_ARGUMENTS and CTI_ARGUMENTS_FASTCALL
+
+ This is a small regression for GCC 4.0, but simplifies the code
+ for future improvements and lets us focus on GCC 4.2+ and MSVC.
+
+ * VM/CTI.cpp:
+ * VM/CTI.h:
+ * VM/Machine.cpp:
+ (JSC::Machine::cti_op_convert_this):
+ (JSC::Machine::cti_op_end):
+ (JSC::Machine::cti_op_add):
+ (JSC::Machine::cti_op_pre_inc):
+ (JSC::Machine::cti_timeout_check):
+ (JSC::Machine::cti_register_file_check):
+ (JSC::Machine::cti_op_loop_if_less):
+ (JSC::Machine::cti_op_loop_if_lesseq):
+ (JSC::Machine::cti_op_new_object):
+ (JSC::Machine::cti_op_put_by_id):
+ (JSC::Machine::cti_op_put_by_id_second):
+ (JSC::Machine::cti_op_put_by_id_generic):
+ (JSC::Machine::cti_op_put_by_id_fail):
+ (JSC::Machine::cti_op_get_by_id):
+ (JSC::Machine::cti_op_get_by_id_second):
+ (JSC::Machine::cti_op_get_by_id_generic):
+ (JSC::Machine::cti_op_get_by_id_fail):
+ (JSC::Machine::cti_op_instanceof):
+ (JSC::Machine::cti_op_del_by_id):
+ (JSC::Machine::cti_op_mul):
+ (JSC::Machine::cti_op_new_func):
+ (JSC::Machine::cti_op_call_JSFunction):
+ (JSC::Machine::cti_vm_compile):
+ (JSC::Machine::cti_op_push_activation):
+ (JSC::Machine::cti_op_call_NotJSFunction):
+ (JSC::Machine::cti_op_create_arguments):
+ (JSC::Machine::cti_op_tear_off_activation):
+ (JSC::Machine::cti_op_tear_off_arguments):
+ (JSC::Machine::cti_op_ret_profiler):
+ (JSC::Machine::cti_op_ret_scopeChain):
+ (JSC::Machine::cti_op_new_array):
+ (JSC::Machine::cti_op_resolve):
+ (JSC::Machine::cti_op_construct_JSConstruct):
+ (JSC::Machine::cti_op_construct_NotJSConstruct):
+ (JSC::Machine::cti_op_get_by_val):
+ (JSC::Machine::cti_op_resolve_func):
+ (JSC::Machine::cti_op_sub):
+ (JSC::Machine::cti_op_put_by_val):
+ (JSC::Machine::cti_op_put_by_val_array):
+ (JSC::Machine::cti_op_lesseq):
+ (JSC::Machine::cti_op_loop_if_true):
+ (JSC::Machine::cti_op_negate):
+ (JSC::Machine::cti_op_resolve_base):
+ (JSC::Machine::cti_op_resolve_skip):
+ (JSC::Machine::cti_op_resolve_global):
+ (JSC::Machine::cti_op_div):
+ (JSC::Machine::cti_op_pre_dec):
+ (JSC::Machine::cti_op_jless):
+ (JSC::Machine::cti_op_not):
+ (JSC::Machine::cti_op_jtrue):
+ (JSC::Machine::cti_op_post_inc):
+ (JSC::Machine::cti_op_eq):
+ (JSC::Machine::cti_op_lshift):
+ (JSC::Machine::cti_op_bitand):
+ (JSC::Machine::cti_op_rshift):
+ (JSC::Machine::cti_op_bitnot):
+ (JSC::Machine::cti_op_resolve_with_base):
+ (JSC::Machine::cti_op_new_func_exp):
+ (JSC::Machine::cti_op_mod):
+ (JSC::Machine::cti_op_less):
+ (JSC::Machine::cti_op_neq):
+ (JSC::Machine::cti_op_post_dec):
+ (JSC::Machine::cti_op_urshift):
+ (JSC::Machine::cti_op_bitxor):
+ (JSC::Machine::cti_op_new_regexp):
+ (JSC::Machine::cti_op_bitor):
+ (JSC::Machine::cti_op_call_eval):
+ (JSC::Machine::cti_op_throw):
+ (JSC::Machine::cti_op_get_pnames):
+ (JSC::Machine::cti_op_next_pname):
+ (JSC::Machine::cti_op_push_scope):
+ (JSC::Machine::cti_op_pop_scope):
+ (JSC::Machine::cti_op_typeof):
+ (JSC::Machine::cti_op_is_undefined):
+ (JSC::Machine::cti_op_is_boolean):
+ (JSC::Machine::cti_op_is_number):
+ (JSC::Machine::cti_op_is_string):
+ (JSC::Machine::cti_op_is_object):
+ (JSC::Machine::cti_op_is_function):
+ (JSC::Machine::cti_op_stricteq):
+ (JSC::Machine::cti_op_nstricteq):
+ (JSC::Machine::cti_op_to_jsnumber):
+ (JSC::Machine::cti_op_in):
+ (JSC::Machine::cti_op_push_new_scope):
+ (JSC::Machine::cti_op_jmp_scopes):
+ (JSC::Machine::cti_op_put_by_index):
+ (JSC::Machine::cti_op_switch_imm):
+ (JSC::Machine::cti_op_switch_char):
+ (JSC::Machine::cti_op_switch_string):
+ (JSC::Machine::cti_op_del_by_val):
+ (JSC::Machine::cti_op_put_getter):
+ (JSC::Machine::cti_op_put_setter):
+ (JSC::Machine::cti_op_new_error):
+ (JSC::Machine::cti_op_debug):
+ (JSC::Machine::cti_vm_throw):
+ * VM/Machine.h:
+ * masm/X86Assembler.h:
+ (JSC::X86Assembler::emitRestoreArgumentReference):
+ (JSC::X86Assembler::emitRestoreArgumentReferenceForTrampoline):
+ * wtf/Platform.h:
+
2008-10-13 Maciej Stachowiak <mjs@apple.com>
Reviewed by Cameron Zwarich.
asm(
".globl " SYMBOL_STRING(ctiVMThrowTrampoline) "\n"
SYMBOL_STRING(ctiVMThrowTrampoline) ":" "\n"
-#if USE(CTI_ARGUMENT)
-#if USE(FAST_CALL_CTI_ARGUMENT)
"movl %esp, %ecx" "\n"
-#else
- "movl %esp, 0(%esp)" "\n"
-#endif
"call " SYMBOL_STRING(_ZN3JSC7Machine12cti_vm_throwEPPv) "\n"
-#else
- "call " SYMBOL_STRING(_ZN3JSC7Machine12cti_vm_throwEPv) "\n"
-#endif
"addl $0x24, %esp" "\n"
"popl %edi" "\n"
"popl %esi" "\n"
#define CTI_ARGS_exception 0x0F
#define CTI_ARGS_profilerReference 0x10
#define CTI_ARGS_globalData 0x11
-#define ARG_registerFile ((RegisterFile*)(ARGS)[CTI_ARGS_registerFile])
-#define ARG_callFrame ((CallFrame*)(ARGS)[CTI_ARGS_callFrame])
-#define ARG_exception ((JSValue**)(ARGS)[CTI_ARGS_exception])
-#define ARG_profilerReference ((Profiler**)(ARGS)[CTI_ARGS_profilerReference])
-#define ARG_globalData ((JSGlobalData*)(ARGS)[CTI_ARGS_globalData])
-
-#define ARG_setCallFrame(newCallFrame) (*(CallFrame**)&(ARGS)[CTI_ARGS_callFrame] = (newCallFrame))
-
-#define ARG_src1 ((JSValue*)((ARGS)[1]))
-#define ARG_src2 ((JSValue*)((ARGS)[2]))
-#define ARG_src3 ((JSValue*)((ARGS)[3]))
-#define ARG_src4 ((JSValue*)((ARGS)[4]))
-#define ARG_src5 ((JSValue*)((ARGS)[5]))
-#define ARG_id1 ((Identifier*)((ARGS)[1]))
-#define ARG_id2 ((Identifier*)((ARGS)[2]))
-#define ARG_id3 ((Identifier*)((ARGS)[3]))
-#define ARG_id4 ((Identifier*)((ARGS)[4]))
-#define ARG_int1 ((int)((ARGS)[1]))
-#define ARG_int2 ((int)((ARGS)[2]))
-#define ARG_int3 ((int)((ARGS)[3]))
-#define ARG_int4 ((int)((ARGS)[4]))
-#define ARG_int5 ((int)((ARGS)[5]))
-#define ARG_func1 ((FuncDeclNode*)((ARGS)[1]))
-#define ARG_funcexp1 ((FuncExprNode*)((ARGS)[1]))
-#define ARG_registers1 ((Register*)((ARGS)[1]))
-#define ARG_regexp1 ((RegExp*)((ARGS)[1]))
-#define ARG_pni1 ((JSPropertyNameIterator*)((ARGS)[1]))
-#define ARG_instr1 ((Instruction*)((ARGS)[1]))
-#define ARG_instr2 ((Instruction*)((ARGS)[2]))
-#define ARG_instr3 ((Instruction*)((ARGS)[3]))
-#define ARG_instr4 ((Instruction*)((ARGS)[4]))
-#define ARG_instr5 ((Instruction*)((ARGS)[5]))
-#define ARG_instr6 ((Instruction*)((ARGS)[6]))
-
-#define CTI_RETURN_ADDRESS ((ARGS)[-1])
+#define ARG_registerFile ((RegisterFile*)(args)[CTI_ARGS_registerFile])
+#define ARG_callFrame ((CallFrame*)(args)[CTI_ARGS_callFrame])
+#define ARG_exception ((JSValue**)(args)[CTI_ARGS_exception])
+#define ARG_profilerReference ((Profiler**)(args)[CTI_ARGS_profilerReference])
+#define ARG_globalData ((JSGlobalData*)(args)[CTI_ARGS_globalData])
+
+#define ARG_setCallFrame(newCallFrame) (*(CallFrame**)&(args)[CTI_ARGS_callFrame] = (newCallFrame))
+
+#define ARG_src1 ((JSValue*)((args)[1]))
+#define ARG_src2 ((JSValue*)((args)[2]))
+#define ARG_src3 ((JSValue*)((args)[3]))
+#define ARG_src4 ((JSValue*)((args)[4]))
+#define ARG_src5 ((JSValue*)((args)[5]))
+#define ARG_id1 ((Identifier*)((args)[1]))
+#define ARG_id2 ((Identifier*)((args)[2]))
+#define ARG_id3 ((Identifier*)((args)[3]))
+#define ARG_id4 ((Identifier*)((args)[4]))
+#define ARG_int1 ((int)((args)[1]))
+#define ARG_int2 ((int)((args)[2]))
+#define ARG_int3 ((int)((args)[3]))
+#define ARG_int4 ((int)((args)[4]))
+#define ARG_int5 ((int)((args)[5]))
+#define ARG_func1 ((FuncDeclNode*)((args)[1]))
+#define ARG_funcexp1 ((FuncExprNode*)((args)[1]))
+#define ARG_registers1 ((Register*)((args)[1]))
+#define ARG_regexp1 ((RegExp*)((args)[1]))
+#define ARG_pni1 ((JSPropertyNameIterator*)((args)[1]))
+#define ARG_instr1 ((Instruction*)((args)[1]))
+#define ARG_instr2 ((Instruction*)((args)[2]))
+#define ARG_instr3 ((Instruction*)((args)[3]))
+#define ARG_instr4 ((Instruction*)((args)[4]))
+#define ARG_instr5 ((Instruction*)((args)[5]))
+#define ARG_instr6 ((Instruction*)((args)[6]))
+
+#define CTI_RETURN_ADDRESS ((args)[-1])
namespace JSC {
struct Instruction;
struct OperandTypes;
- typedef JSValue* (SFX_CALL *CTIHelper_j)(CTI_ARGS);
- typedef JSPropertyNameIterator* (SFX_CALL *CTIHelper_p)(CTI_ARGS);
- typedef void (SFX_CALL *CTIHelper_v)(CTI_ARGS);
- typedef void* (SFX_CALL *CTIHelper_s)(CTI_ARGS);
- typedef int (SFX_CALL *CTIHelper_b)(CTI_ARGS);
- typedef VoidPtrPair (SFX_CALL *CTIHelper_2)(CTI_ARGS);
+ typedef JSValue* (SFX_CALL *CTIHelper_j)(void** args);
+ typedef JSPropertyNameIterator* (SFX_CALL *CTIHelper_p)(void** args);
+ typedef void (SFX_CALL *CTIHelper_v)(void** args);
+ typedef void* (SFX_CALL *CTIHelper_s)(void** args);
+ typedef int (SFX_CALL *CTIHelper_b)(void** args);
+ typedef VoidPtrPair (SFX_CALL *CTIHelper_2)(void** args);
struct CallRecord {
X86Assembler::JmpSrc from;
// will compress the displacement, and we may not be able to fit a repatched offset.
static const int repatchGetByIdDefaultOffset = 256;
-#if USE(FAST_CALL_CTI_ARGUMENT)
static const int ctiArgumentInitSize = 2;
-#elif USE(CTI_ARGUMENT)
- static const int ctiArgumentInitSize = 4;
-#else
- static const int ctiArgumentInitSize = 0;
-#endif
+
// These architecture specific value are used to enable repatching - see comment on op_put_by_id.
static const int repatchOffsetPutByIdStructureID = 19;
static const int repatchOffsetPutByIdPropertyMapOffset = 34;
} \
} while (0)
-JSValue* Machine::cti_op_convert_this(CTI_ARGS)
+JSValue* Machine::cti_op_convert_this(void** args)
{
JSValue* v1 = ARG_src1;
CallFrame* callFrame = ARG_callFrame;
return result;
}
-void Machine::cti_op_end(CTI_ARGS)
+void Machine::cti_op_end(void** args)
{
ScopeChainNode* scopeChain = ARG_callFrame->scopeChain();
ASSERT(scopeChain->refCount > 1);
scopeChain->deref();
}
-JSValue* Machine::cti_op_add(CTI_ARGS)
+JSValue* Machine::cti_op_add(void** args)
{
JSValue* v1 = ARG_src1;
JSValue* v2 = ARG_src2;
return result;
}
-JSValue* Machine::cti_op_pre_inc(CTI_ARGS)
+JSValue* Machine::cti_op_pre_inc(void** args)
{
JSValue* v = ARG_src1;
return result;
}
-void Machine::cti_timeout_check(CTI_ARGS)
+void Machine::cti_timeout_check(void** args)
{
if (ARG_globalData->machine->checkTimeout(ARG_callFrame->dynamicGlobalObject())) {
ARG_globalData->exception = createInterruptedExecutionException(ARG_globalData);
}
}
-void Machine::cti_register_file_check(CTI_ARGS)
+void Machine::cti_register_file_check(void** args)
{
CallFrame* callFrame = ARG_callFrame;
CodeBlock* codeBlock = callFrame->codeBlock();
}
}
-int Machine::cti_op_loop_if_less(CTI_ARGS)
+int Machine::cti_op_loop_if_less(void** args)
{
JSValue* src1 = ARG_src1;
JSValue* src2 = ARG_src2;
return result;
}
-int Machine::cti_op_loop_if_lesseq(CTI_ARGS)
+int Machine::cti_op_loop_if_lesseq(void** args)
{
JSValue* src1 = ARG_src1;
JSValue* src2 = ARG_src2;
return result;
}
-JSValue* Machine::cti_op_new_object(CTI_ARGS)
+JSValue* Machine::cti_op_new_object(void** args)
{
return constructEmptyObject(ARG_callFrame);;
}
-void Machine::cti_op_put_by_id(CTI_ARGS)
+void Machine::cti_op_put_by_id(void** args)
{
CallFrame* callFrame = ARG_callFrame;
Identifier& ident = *ARG_id2;
VM_CHECK_EXCEPTION_AT_END();
}
-void Machine::cti_op_put_by_id_second(CTI_ARGS)
+void Machine::cti_op_put_by_id_second(void** args)
{
PutPropertySlot slot;
ARG_src1->put(ARG_callFrame, *ARG_id2, ARG_src3, slot);
VM_CHECK_EXCEPTION_AT_END();
}
-void Machine::cti_op_put_by_id_generic(CTI_ARGS)
+void Machine::cti_op_put_by_id_generic(void** args)
{
PutPropertySlot slot;
ARG_src1->put(ARG_callFrame, *ARG_id2, ARG_src3, slot);
VM_CHECK_EXCEPTION_AT_END();
}
-void Machine::cti_op_put_by_id_fail(CTI_ARGS)
+void Machine::cti_op_put_by_id_fail(void** args)
{
CallFrame* callFrame = ARG_callFrame;
Identifier& ident = *ARG_id2;
VM_CHECK_EXCEPTION_AT_END();
}
-JSValue* Machine::cti_op_get_by_id(CTI_ARGS)
+JSValue* Machine::cti_op_get_by_id(void** args)
{
CallFrame* callFrame = ARG_callFrame;
Identifier& ident = *ARG_id2;
return result;
}
-JSValue* Machine::cti_op_get_by_id_second(CTI_ARGS)
+JSValue* Machine::cti_op_get_by_id_second(void** args)
{
CallFrame* callFrame = ARG_callFrame;
Identifier& ident = *ARG_id2;
return result;
}
-JSValue* Machine::cti_op_get_by_id_generic(CTI_ARGS)
+JSValue* Machine::cti_op_get_by_id_generic(void** args)
{
CallFrame* callFrame = ARG_callFrame;
Identifier& ident = *ARG_id2;
return result;
}
-JSValue* Machine::cti_op_get_by_id_fail(CTI_ARGS)
+JSValue* Machine::cti_op_get_by_id_fail(void** args)
{
CallFrame* callFrame = ARG_callFrame;
Identifier& ident = *ARG_id2;
return result;
}
-JSValue* Machine::cti_op_instanceof(CTI_ARGS)
+JSValue* Machine::cti_op_instanceof(void** args)
{
CallFrame* callFrame = ARG_callFrame;
JSValue* value = ARG_src1;
return result;
}
-JSValue* Machine::cti_op_del_by_id(CTI_ARGS)
+JSValue* Machine::cti_op_del_by_id(void** args)
{
CallFrame* callFrame = ARG_callFrame;
Identifier& ident = *ARG_id2;
return result;
}
-JSValue* Machine::cti_op_mul(CTI_ARGS)
+JSValue* Machine::cti_op_mul(void** args)
{
JSValue* src1 = ARG_src1;
JSValue* src2 = ARG_src2;
return result;
}
-JSValue* Machine::cti_op_new_func(CTI_ARGS)
+JSValue* Machine::cti_op_new_func(void** args)
{
return ARG_func1->makeFunction(ARG_callFrame, ARG_callFrame->scopeChain());
}
-VoidPtrPair Machine::cti_op_call_JSFunction(CTI_ARGS)
+VoidPtrPair Machine::cti_op_call_JSFunction(void** args)
{
#ifndef NDEBUG
CallData callData;
return pair;
}
-void* Machine::cti_vm_compile(CTI_ARGS)
+void* Machine::cti_vm_compile(void** args)
{
CodeBlock* codeBlock = ARG_callFrame->codeBlock();
if (!codeBlock->ctiCode)
return codeBlock->ctiCode;
}
-JSValue* Machine::cti_op_push_activation(CTI_ARGS)
+JSValue* Machine::cti_op_push_activation(void** args)
{
JSActivation* activation = new (ARG_globalData) JSActivation(ARG_callFrame, static_cast<FunctionBodyNode*>(ARG_callFrame->codeBlock()->ownerNode));
ARG_callFrame->setScopeChain(ARG_callFrame->scopeChain()->copy()->push(activation));
return activation;
}
-JSValue* Machine::cti_op_call_NotJSFunction(CTI_ARGS)
+JSValue* Machine::cti_op_call_NotJSFunction(void** args)
{
JSValue* funcVal = ARG_src1;
VM_THROW_EXCEPTION();
}
-void Machine::cti_op_create_arguments(CTI_ARGS)
+void Machine::cti_op_create_arguments(void** args)
{
Arguments* arguments = new (ARG_globalData) Arguments(ARG_callFrame);
ARG_callFrame->setCalleeArguments(arguments);
ARG_callFrame[RegisterFile::ArgumentsRegister] = arguments;
}
-void Machine::cti_op_tear_off_activation(CTI_ARGS)
+void Machine::cti_op_tear_off_activation(void** args)
{
ASSERT(ARG_callFrame->codeBlock()->needsFullScopeChain);
ASSERT(ARG_src1->isObject(&JSActivation::info));
static_cast<JSActivation*>(ARG_src1)->copyRegisters(ARG_callFrame->optionalCalleeArguments());
}
-void Machine::cti_op_tear_off_arguments(CTI_ARGS)
+void Machine::cti_op_tear_off_arguments(void** args)
{
ASSERT(ARG_callFrame->codeBlock()->usesArguments && !ARG_callFrame->codeBlock()->needsFullScopeChain);
ARG_callFrame->optionalCalleeArguments()->copyRegisters();
}
-void Machine::cti_op_ret_profiler(CTI_ARGS)
+void Machine::cti_op_ret_profiler(void** args)
{
ASSERT(*ARG_profilerReference);
(*ARG_profilerReference)->didExecute(ARG_callFrame, ARG_callFrame->callee());
}
-void Machine::cti_op_ret_scopeChain(CTI_ARGS)
+void Machine::cti_op_ret_scopeChain(void** args)
{
ASSERT(ARG_callFrame->codeBlock()->needsFullScopeChain);
ARG_callFrame->scopeChain()->deref();
}
-JSValue* Machine::cti_op_new_array(CTI_ARGS)
+JSValue* Machine::cti_op_new_array(void** args)
{
ArgList argList(ARG_registers1, ARG_int2);
return constructArray(ARG_callFrame, argList);
}
-JSValue* Machine::cti_op_resolve(CTI_ARGS)
+JSValue* Machine::cti_op_resolve(void** args)
{
CallFrame* callFrame = ARG_callFrame;
ScopeChainNode* scopeChain = callFrame->scopeChain();
VM_THROW_EXCEPTION();
}
-VoidPtrPair Machine::cti_op_construct_JSConstruct(CTI_ARGS)
+VoidPtrPair Machine::cti_op_construct_JSConstruct(void** args)
{
CallFrame* callFrame = ARG_callFrame;
return pair;
}
-JSValue* Machine::cti_op_construct_NotJSConstruct(CTI_ARGS)
+JSValue* Machine::cti_op_construct_NotJSConstruct(void** args)
{
CallFrame* callFrame = ARG_callFrame;
VM_THROW_EXCEPTION();
}
-JSValue* Machine::cti_op_get_by_val(CTI_ARGS)
+JSValue* Machine::cti_op_get_by_val(void** args)
{
CallFrame* callFrame = ARG_callFrame;
Machine* machine = ARG_globalData->machine;
return result;
}
-VoidPtrPair Machine::cti_op_resolve_func(CTI_ARGS)
+VoidPtrPair Machine::cti_op_resolve_func(void** args)
{
CallFrame* callFrame = ARG_callFrame;
ScopeChainNode* scopeChain = callFrame->scopeChain();
VM_THROW_EXCEPTION_2();
}
-JSValue* Machine::cti_op_sub(CTI_ARGS)
+JSValue* Machine::cti_op_sub(void** args)
{
JSValue* src1 = ARG_src1;
JSValue* src2 = ARG_src2;
return result;
}
-void Machine::cti_op_put_by_val(CTI_ARGS)
+void Machine::cti_op_put_by_val(void** args)
{
CallFrame* callFrame = ARG_callFrame;
Machine* machine = ARG_globalData->machine;
VM_CHECK_EXCEPTION_AT_END();
}
-void Machine::cti_op_put_by_val_array(CTI_ARGS)
+void Machine::cti_op_put_by_val_array(void** args)
{
CallFrame* callFrame = ARG_callFrame;
VM_CHECK_EXCEPTION_AT_END();
}
-JSValue* Machine::cti_op_lesseq(CTI_ARGS)
+JSValue* Machine::cti_op_lesseq(void** args)
{
CallFrame* callFrame = ARG_callFrame;
JSValue* result = jsBoolean(jsLessEq(callFrame, ARG_src1, ARG_src2));
return result;
}
-int Machine::cti_op_loop_if_true(CTI_ARGS)
+int Machine::cti_op_loop_if_true(void** args)
{
JSValue* src1 = ARG_src1;
return result;
}
-JSValue* Machine::cti_op_negate(CTI_ARGS)
+JSValue* Machine::cti_op_negate(void** args)
{
JSValue* src = ARG_src1;
return result;
}
-JSValue* Machine::cti_op_resolve_base(CTI_ARGS)
+JSValue* Machine::cti_op_resolve_base(void** args)
{
return inlineResolveBase(ARG_callFrame, *ARG_id1, ARG_callFrame->scopeChain());
}
-JSValue* Machine::cti_op_resolve_skip(CTI_ARGS)
+JSValue* Machine::cti_op_resolve_skip(void** args)
{
CallFrame* callFrame = ARG_callFrame;
ScopeChainNode* scopeChain = callFrame->scopeChain();
VM_THROW_EXCEPTION();
}
-JSValue* Machine::cti_op_resolve_global(CTI_ARGS)
+JSValue* Machine::cti_op_resolve_global(void** args)
{
CallFrame* callFrame = ARG_callFrame;
JSGlobalObject* globalObject = static_cast<JSGlobalObject*>(ARG_src1);
VM_THROW_EXCEPTION();
}
-JSValue* Machine::cti_op_div(CTI_ARGS)
+JSValue* Machine::cti_op_div(void** args)
{
JSValue* src1 = ARG_src1;
JSValue* src2 = ARG_src2;
return result;
}
-JSValue* Machine::cti_op_pre_dec(CTI_ARGS)
+JSValue* Machine::cti_op_pre_dec(void** args)
{
JSValue* v = ARG_src1;
return result;
}
-int Machine::cti_op_jless(CTI_ARGS)
+int Machine::cti_op_jless(void** args)
{
JSValue* src1 = ARG_src1;
JSValue* src2 = ARG_src2;
return result;
}
-JSValue* Machine::cti_op_not(CTI_ARGS)
+JSValue* Machine::cti_op_not(void** args)
{
JSValue* src = ARG_src1;
return result;
}
-int SFX_CALL Machine::cti_op_jtrue(CTI_ARGS)
+int SFX_CALL Machine::cti_op_jtrue(void** args)
{
JSValue* src1 = ARG_src1;
return result;
}
-VoidPtrPair Machine::cti_op_post_inc(CTI_ARGS)
+VoidPtrPair Machine::cti_op_post_inc(void** args)
{
JSValue* v = ARG_src1;
return pair;
}
-JSValue* Machine::cti_op_eq(CTI_ARGS)
+JSValue* Machine::cti_op_eq(void** args)
{
JSValue* src1 = ARG_src1;
JSValue* src2 = ARG_src2;
return result;
}
-JSValue* Machine::cti_op_lshift(CTI_ARGS)
+JSValue* Machine::cti_op_lshift(void** args)
{
JSValue* val = ARG_src1;
JSValue* shift = ARG_src2;
return result;
}
-JSValue* Machine::cti_op_bitand(CTI_ARGS)
+JSValue* Machine::cti_op_bitand(void** args)
{
JSValue* src1 = ARG_src1;
JSValue* src2 = ARG_src2;
return result;
}
-JSValue* Machine::cti_op_rshift(CTI_ARGS)
+JSValue* Machine::cti_op_rshift(void** args)
{
JSValue* val = ARG_src1;
JSValue* shift = ARG_src2;
return result;
}
-JSValue* Machine::cti_op_bitnot(CTI_ARGS)
+JSValue* Machine::cti_op_bitnot(void** args)
{
JSValue* src = ARG_src1;
return result;
}
-VoidPtrPair Machine::cti_op_resolve_with_base(CTI_ARGS)
+VoidPtrPair Machine::cti_op_resolve_with_base(void** args)
{
CallFrame* callFrame = ARG_callFrame;
ScopeChainNode* scopeChain = callFrame->scopeChain();
VM_THROW_EXCEPTION_2();
}
-JSValue* Machine::cti_op_new_func_exp(CTI_ARGS)
+JSValue* Machine::cti_op_new_func_exp(void** args)
{
return ARG_funcexp1->makeFunction(ARG_callFrame, ARG_callFrame->scopeChain());
}
-JSValue* Machine::cti_op_mod(CTI_ARGS)
+JSValue* Machine::cti_op_mod(void** args)
{
JSValue* dividendValue = ARG_src1;
JSValue* divisorValue = ARG_src2;
return result;
}
-JSValue* Machine::cti_op_less(CTI_ARGS)
+JSValue* Machine::cti_op_less(void** args)
{
CallFrame* callFrame = ARG_callFrame;
JSValue* result = jsBoolean(jsLess(callFrame, ARG_src1, ARG_src2));
return result;
}
-JSValue* Machine::cti_op_neq(CTI_ARGS)
+JSValue* Machine::cti_op_neq(void** args)
{
JSValue* src1 = ARG_src1;
JSValue* src2 = ARG_src2;
return result;
}
-VoidPtrPair Machine::cti_op_post_dec(CTI_ARGS)
+VoidPtrPair Machine::cti_op_post_dec(void** args)
{
JSValue* v = ARG_src1;
return pair;
}
-JSValue* Machine::cti_op_urshift(CTI_ARGS)
+JSValue* Machine::cti_op_urshift(void** args)
{
JSValue* val = ARG_src1;
JSValue* shift = ARG_src2;
}
}
-JSValue* Machine::cti_op_bitxor(CTI_ARGS)
+JSValue* Machine::cti_op_bitxor(void** args)
{
JSValue* src1 = ARG_src1;
JSValue* src2 = ARG_src2;
return result;
}
-JSValue* Machine::cti_op_new_regexp(CTI_ARGS)
+JSValue* Machine::cti_op_new_regexp(void** args)
{
return new (ARG_globalData) RegExpObject(ARG_callFrame->lexicalGlobalObject()->regExpStructure(), ARG_regexp1);
}
-JSValue* Machine::cti_op_bitor(CTI_ARGS)
+JSValue* Machine::cti_op_bitor(void** args)
{
JSValue* src1 = ARG_src1;
JSValue* src2 = ARG_src2;
return result;
}
-JSValue* Machine::cti_op_call_eval(CTI_ARGS)
+JSValue* Machine::cti_op_call_eval(void** args)
{
CallFrame* callFrame = ARG_callFrame;
RegisterFile* registerFile = ARG_registerFile;
return JSImmediate::impossibleValue();
}
-void* Machine::cti_op_throw(CTI_ARGS)
+void* Machine::cti_op_throw(void** args)
{
CallFrame* callFrame = ARG_callFrame;
CodeBlock* codeBlock = callFrame->codeBlock();
return exceptionValue;
}
-JSPropertyNameIterator* Machine::cti_op_get_pnames(CTI_ARGS)
+JSPropertyNameIterator* Machine::cti_op_get_pnames(void** args)
{
return JSPropertyNameIterator::create(ARG_callFrame, ARG_src1);
}
-JSValue* Machine::cti_op_next_pname(CTI_ARGS)
+JSValue* Machine::cti_op_next_pname(void** args)
{
JSPropertyNameIterator* it = ARG_pni1;
JSValue* temp = it->next(ARG_callFrame);
return temp;
}
-void Machine::cti_op_push_scope(CTI_ARGS)
+void Machine::cti_op_push_scope(void** args)
{
JSObject* o = ARG_src1->toObject(ARG_callFrame);
VM_CHECK_EXCEPTION_VOID();
ARG_callFrame->setScopeChain(ARG_callFrame->scopeChain()->push(o));
}
-void Machine::cti_op_pop_scope(CTI_ARGS)
+void Machine::cti_op_pop_scope(void** args)
{
ARG_callFrame->setScopeChain(ARG_callFrame->scopeChain()->pop());
}
-JSValue* Machine::cti_op_typeof(CTI_ARGS)
+JSValue* Machine::cti_op_typeof(void** args)
{
return jsTypeStringForValue(ARG_callFrame, ARG_src1);
}
-JSValue* Machine::cti_op_is_undefined(CTI_ARGS)
+JSValue* Machine::cti_op_is_undefined(void** args)
{
JSValue* v = ARG_src1;
return jsBoolean(JSImmediate::isImmediate(v) ? v->isUndefined() : v->asCell()->structureID()->typeInfo().masqueradesAsUndefined());
}
-JSValue* Machine::cti_op_is_boolean(CTI_ARGS)
+JSValue* Machine::cti_op_is_boolean(void** args)
{
return jsBoolean(ARG_src1->isBoolean());
}
-JSValue* Machine::cti_op_is_number(CTI_ARGS)
+JSValue* Machine::cti_op_is_number(void** args)
{
return jsBoolean(ARG_src1->isNumber());
}
-JSValue* Machine::cti_op_is_string(CTI_ARGS)
+JSValue* Machine::cti_op_is_string(void** args)
{
return jsBoolean(ARG_globalData->machine->isJSString(ARG_src1));
}
-JSValue* Machine::cti_op_is_object(CTI_ARGS)
+JSValue* Machine::cti_op_is_object(void** args)
{
return jsBoolean(jsIsObjectType(ARG_src1));
}
-JSValue* Machine::cti_op_is_function(CTI_ARGS)
+JSValue* Machine::cti_op_is_function(void** args)
{
return jsBoolean(jsIsFunctionType(ARG_src1));
}
-JSValue* Machine::cti_op_stricteq(CTI_ARGS)
+JSValue* Machine::cti_op_stricteq(void** args)
{
JSValue* src1 = ARG_src1;
JSValue* src2 = ARG_src2;
return jsBoolean(strictEqualSlowCaseInline(src1, src2));
}
-JSValue* Machine::cti_op_nstricteq(CTI_ARGS)
+JSValue* Machine::cti_op_nstricteq(void** args)
{
JSValue* src1 = ARG_src1;
JSValue* src2 = ARG_src2;
return jsBoolean(!strictEqualSlowCaseInline(src1, src2));
}
-JSValue* Machine::cti_op_to_jsnumber(CTI_ARGS)
+JSValue* Machine::cti_op_to_jsnumber(void** args)
{
JSValue* src = ARG_src1;
CallFrame* callFrame = ARG_callFrame;
return result;
}
-JSValue* Machine::cti_op_in(CTI_ARGS)
+JSValue* Machine::cti_op_in(void** args)
{
CallFrame* callFrame = ARG_callFrame;
JSValue* baseVal = ARG_src2;
return jsBoolean(baseObj->hasProperty(callFrame, property));
}
-JSValue* Machine::cti_op_push_new_scope(CTI_ARGS)
+JSValue* Machine::cti_op_push_new_scope(void** args)
{
JSObject* scope = new (ARG_globalData) JSStaticScopeObject(ARG_callFrame, *ARG_id1, ARG_src2, DontDelete);
return scope;
}
-void Machine::cti_op_jmp_scopes(CTI_ARGS)
+void Machine::cti_op_jmp_scopes(void** args)
{
unsigned count = ARG_int1;
CallFrame* callFrame = ARG_callFrame;
callFrame->setScopeChain(tmp);
}
-void Machine::cti_op_put_by_index(CTI_ARGS)
+void Machine::cti_op_put_by_index(void** args)
{
CallFrame* callFrame = ARG_callFrame;
unsigned property = ARG_int2;
ARG_src1->put(callFrame, property, ARG_src3);
}
-void* Machine::cti_op_switch_imm(CTI_ARGS)
+void* Machine::cti_op_switch_imm(void** args)
{
JSValue* scrutinee = ARG_src1;
unsigned tableIndex = ARG_int2;
return codeBlock->immediateSwitchJumpTables[tableIndex].ctiDefault;
}
-void* Machine::cti_op_switch_char(CTI_ARGS)
+void* Machine::cti_op_switch_char(void** args)
{
JSValue* scrutinee = ARG_src1;
unsigned tableIndex = ARG_int2;
return result;
}
-void* Machine::cti_op_switch_string(CTI_ARGS)
+void* Machine::cti_op_switch_string(void** args)
{
JSValue* scrutinee = ARG_src1;
unsigned tableIndex = ARG_int2;
return result;
}
-JSValue* Machine::cti_op_del_by_val(CTI_ARGS)
+JSValue* Machine::cti_op_del_by_val(void** args)
{
CallFrame* callFrame = ARG_callFrame;
return result;
}
-void Machine::cti_op_put_getter(CTI_ARGS)
+void Machine::cti_op_put_getter(void** args)
{
CallFrame* callFrame = ARG_callFrame;
baseObj->defineGetter(callFrame, ident, static_cast<JSObject*>(ARG_src3));
}
-void Machine::cti_op_put_setter(CTI_ARGS)
+void Machine::cti_op_put_setter(void** args)
{
CallFrame* callFrame = ARG_callFrame;
baseObj->defineSetter(callFrame, ident, static_cast<JSObject*>(ARG_src3));
}
-JSValue* Machine::cti_op_new_error(CTI_ARGS)
+JSValue* Machine::cti_op_new_error(void** args)
{
CallFrame* callFrame = ARG_callFrame;
CodeBlock* codeBlock = callFrame->codeBlock();
return Error::create(callFrame, static_cast<ErrorType>(type), message->toString(callFrame), lineNumber, codeBlock->ownerNode->sourceID(), codeBlock->ownerNode->sourceURL());
}
-void Machine::cti_op_debug(CTI_ARGS)
+void Machine::cti_op_debug(void** args)
{
CallFrame* callFrame = ARG_callFrame;
ARG_globalData->machine->debug(callFrame, static_cast<DebugHookID>(debugHookID), firstLine, lastLine);
}
-void* Machine::cti_vm_throw(CTI_ARGS)
+void* Machine::cti_vm_throw(void** args)
{
CallFrame* callFrame = ARG_callFrame;
CodeBlock* codeBlock = callFrame->codeBlock();
#if ENABLE(CTI)
-#if USE(CTI_ARGUMENT)
-#define CTI_ARGS void** args
-#define ARGS (args)
-#else
-#define CTI_ARGS void* args
-#define ARGS (&args)
-#endif
-
-#if USE(FAST_CALL_CTI_ARGUMENT)
-
#if COMPILER(MSVC)
#define SFX_CALL __fastcall
#elif COMPILER(GCC)
#define SFX_CALL __attribute__ ((fastcall))
#else
#error Need to support fastcall calling convention in this compiler
-#endif
-
-#else
-
-#if COMPILER(MSVC)
-#define SFX_CALL __cdecl
-#else
-#define SFX_CALL
-#endif
-
#endif
struct VoidPtrPair { void* first; void* second; };
#if ENABLE(CTI)
- static void SFX_CALL cti_timeout_check(CTI_ARGS);
- static void SFX_CALL cti_register_file_check(CTI_ARGS);
-
- static JSValue* SFX_CALL cti_op_convert_this(CTI_ARGS);
- static void SFX_CALL cti_op_end(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_add(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_pre_inc(CTI_ARGS);
- static int SFX_CALL cti_op_loop_if_less(CTI_ARGS);
- static int SFX_CALL cti_op_loop_if_lesseq(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_new_object(CTI_ARGS);
- static void SFX_CALL cti_op_put_by_id(CTI_ARGS);
- static void SFX_CALL cti_op_put_by_id_second(CTI_ARGS);
- static void SFX_CALL cti_op_put_by_id_generic(CTI_ARGS);
- static void SFX_CALL cti_op_put_by_id_fail(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_get_by_id(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_get_by_id_second(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_get_by_id_generic(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_get_by_id_fail(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_del_by_id(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_instanceof(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_mul(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_new_func(CTI_ARGS);
- static VoidPtrPair SFX_CALL cti_op_call_JSFunction(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_call_NotJSFunction(CTI_ARGS);
- static void SFX_CALL cti_op_create_arguments(CTI_ARGS);
- static void SFX_CALL cti_op_tear_off_activation(CTI_ARGS);
- static void SFX_CALL cti_op_tear_off_arguments(CTI_ARGS);
- static void SFX_CALL cti_op_ret_profiler(CTI_ARGS);
- static void SFX_CALL cti_op_ret_scopeChain(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_new_array(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_resolve(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_resolve_global(CTI_ARGS);
- static VoidPtrPair SFX_CALL cti_op_construct_JSConstruct(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_construct_NotJSConstruct(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_get_by_val(CTI_ARGS);
- static VoidPtrPair SFX_CALL cti_op_resolve_func(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_sub(CTI_ARGS);
- static void SFX_CALL cti_op_put_by_val(CTI_ARGS);
- static void SFX_CALL cti_op_put_by_val_array(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_lesseq(CTI_ARGS);
- static int SFX_CALL cti_op_loop_if_true(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_resolve_base(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_negate(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_resolve_skip(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_div(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_pre_dec(CTI_ARGS);
- static int SFX_CALL cti_op_jless(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_not(CTI_ARGS);
- static int SFX_CALL cti_op_jtrue(CTI_ARGS);
- static VoidPtrPair SFX_CALL cti_op_post_inc(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_eq(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_lshift(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_bitand(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_rshift(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_bitnot(CTI_ARGS);
- static VoidPtrPair SFX_CALL cti_op_resolve_with_base(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_new_func_exp(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_mod(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_less(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_neq(CTI_ARGS);
- static VoidPtrPair SFX_CALL cti_op_post_dec(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_urshift(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_bitxor(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_new_regexp(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_bitor(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_call_eval(CTI_ARGS);
- static void* SFX_CALL cti_op_throw(CTI_ARGS);
- static JSPropertyNameIterator* SFX_CALL cti_op_get_pnames(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_next_pname(CTI_ARGS);
- static void SFX_CALL cti_op_push_scope(CTI_ARGS);
- static void SFX_CALL cti_op_pop_scope(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_typeof(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_is_undefined(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_is_boolean(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_is_number(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_is_string(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_is_object(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_is_function(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_stricteq(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_nstricteq(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_to_jsnumber(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_in(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_push_new_scope(CTI_ARGS);
- static void SFX_CALL cti_op_jmp_scopes(CTI_ARGS);
- static void SFX_CALL cti_op_put_by_index(CTI_ARGS);
- static void* SFX_CALL cti_op_switch_imm(CTI_ARGS);
- static void* SFX_CALL cti_op_switch_char(CTI_ARGS);
- static void* SFX_CALL cti_op_switch_string(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_del_by_val(CTI_ARGS);
- static void SFX_CALL cti_op_put_getter(CTI_ARGS);
- static void SFX_CALL cti_op_put_setter(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_new_error(CTI_ARGS);
- static void SFX_CALL cti_op_debug(CTI_ARGS);
-
- static void* SFX_CALL cti_vm_throw(CTI_ARGS);
- static void* SFX_CALL cti_vm_compile(CTI_ARGS);
- static JSValue* SFX_CALL cti_op_push_activation(CTI_ARGS);
+ static void SFX_CALL cti_timeout_check(void** args);
+ static void SFX_CALL cti_register_file_check(void** args);
+
+ static JSValue* SFX_CALL cti_op_convert_this(void** args);
+ static void SFX_CALL cti_op_end(void** args);
+ static JSValue* SFX_CALL cti_op_add(void** args);
+ static JSValue* SFX_CALL cti_op_pre_inc(void** args);
+ static int SFX_CALL cti_op_loop_if_less(void** args);
+ static int SFX_CALL cti_op_loop_if_lesseq(void** args);
+ static JSValue* SFX_CALL cti_op_new_object(void** args);
+ static void SFX_CALL cti_op_put_by_id(void** args);
+ static void SFX_CALL cti_op_put_by_id_second(void** args);
+ static void SFX_CALL cti_op_put_by_id_generic(void** args);
+ static void SFX_CALL cti_op_put_by_id_fail(void** args);
+ static JSValue* SFX_CALL cti_op_get_by_id(void** args);
+ static JSValue* SFX_CALL cti_op_get_by_id_second(void** args);
+ static JSValue* SFX_CALL cti_op_get_by_id_generic(void** args);
+ static JSValue* SFX_CALL cti_op_get_by_id_fail(void** args);
+ static JSValue* SFX_CALL cti_op_del_by_id(void** args);
+ static JSValue* SFX_CALL cti_op_instanceof(void** args);
+ static JSValue* SFX_CALL cti_op_mul(void** args);
+ static JSValue* SFX_CALL cti_op_new_func(void** args);
+ static VoidPtrPair SFX_CALL cti_op_call_JSFunction(void** args);
+ static JSValue* SFX_CALL cti_op_call_NotJSFunction(void** args);
+ static void SFX_CALL cti_op_create_arguments(void** args);
+ static void SFX_CALL cti_op_tear_off_activation(void** args);
+ static void SFX_CALL cti_op_tear_off_arguments(void** args);
+ static void SFX_CALL cti_op_ret_profiler(void** args);
+ static void SFX_CALL cti_op_ret_scopeChain(void** args);
+ static JSValue* SFX_CALL cti_op_new_array(void** args);
+ static JSValue* SFX_CALL cti_op_resolve(void** args);
+ static JSValue* SFX_CALL cti_op_resolve_global(void** args);
+ static VoidPtrPair SFX_CALL cti_op_construct_JSConstruct(void** args);
+ static JSValue* SFX_CALL cti_op_construct_NotJSConstruct(void** args);
+ static JSValue* SFX_CALL cti_op_get_by_val(void** args);
+ static VoidPtrPair SFX_CALL cti_op_resolve_func(void** args);
+ static JSValue* SFX_CALL cti_op_sub(void** args);
+ static void SFX_CALL cti_op_put_by_val(void** args);
+ static void SFX_CALL cti_op_put_by_val_array(void** args);
+ static JSValue* SFX_CALL cti_op_lesseq(void** args);
+ static int SFX_CALL cti_op_loop_if_true(void** args);
+ static JSValue* SFX_CALL cti_op_resolve_base(void** args);
+ static JSValue* SFX_CALL cti_op_negate(void** args);
+ static JSValue* SFX_CALL cti_op_resolve_skip(void** args);
+ static JSValue* SFX_CALL cti_op_div(void** args);
+ static JSValue* SFX_CALL cti_op_pre_dec(void** args);
+ static int SFX_CALL cti_op_jless(void** args);
+ static JSValue* SFX_CALL cti_op_not(void** args);
+ static int SFX_CALL cti_op_jtrue(void** args);
+ static VoidPtrPair SFX_CALL cti_op_post_inc(void** args);
+ static JSValue* SFX_CALL cti_op_eq(void** args);
+ static JSValue* SFX_CALL cti_op_lshift(void** args);
+ static JSValue* SFX_CALL cti_op_bitand(void** args);
+ static JSValue* SFX_CALL cti_op_rshift(void** args);
+ static JSValue* SFX_CALL cti_op_bitnot(void** args);
+ static VoidPtrPair SFX_CALL cti_op_resolve_with_base(void** args);
+ static JSValue* SFX_CALL cti_op_new_func_exp(void** args);
+ static JSValue* SFX_CALL cti_op_mod(void** args);
+ static JSValue* SFX_CALL cti_op_less(void** args);
+ static JSValue* SFX_CALL cti_op_neq(void** args);
+ static VoidPtrPair SFX_CALL cti_op_post_dec(void** args);
+ static JSValue* SFX_CALL cti_op_urshift(void** args);
+ static JSValue* SFX_CALL cti_op_bitxor(void** args);
+ static JSValue* SFX_CALL cti_op_new_regexp(void** args);
+ static JSValue* SFX_CALL cti_op_bitor(void** args);
+ static JSValue* SFX_CALL cti_op_call_eval(void** args);
+ static void* SFX_CALL cti_op_throw(void** args);
+ static JSPropertyNameIterator* SFX_CALL cti_op_get_pnames(void** args);
+ static JSValue* SFX_CALL cti_op_next_pname(void** args);
+ static void SFX_CALL cti_op_push_scope(void** args);
+ static void SFX_CALL cti_op_pop_scope(void** args);
+ static JSValue* SFX_CALL cti_op_typeof(void** args);
+ static JSValue* SFX_CALL cti_op_is_undefined(void** args);
+ static JSValue* SFX_CALL cti_op_is_boolean(void** args);
+ static JSValue* SFX_CALL cti_op_is_number(void** args);
+ static JSValue* SFX_CALL cti_op_is_string(void** args);
+ static JSValue* SFX_CALL cti_op_is_object(void** args);
+ static JSValue* SFX_CALL cti_op_is_function(void** args);
+ static JSValue* SFX_CALL cti_op_stricteq(void** args);
+ static JSValue* SFX_CALL cti_op_nstricteq(void** args);
+ static JSValue* SFX_CALL cti_op_to_jsnumber(void** args);
+ static JSValue* SFX_CALL cti_op_in(void** args);
+ static JSValue* SFX_CALL cti_op_push_new_scope(void** args);
+ static void SFX_CALL cti_op_jmp_scopes(void** args);
+ static void SFX_CALL cti_op_put_by_index(void** args);
+ static void* SFX_CALL cti_op_switch_imm(void** args);
+ static void* SFX_CALL cti_op_switch_char(void** args);
+ static void* SFX_CALL cti_op_switch_string(void** args);
+ static JSValue* SFX_CALL cti_op_del_by_val(void** args);
+ static void SFX_CALL cti_op_put_getter(void** args);
+ static void SFX_CALL cti_op_put_setter(void** args);
+ static JSValue* SFX_CALL cti_op_new_error(void** args);
+ static void SFX_CALL cti_op_debug(void** args);
+
+ static void* SFX_CALL cti_vm_throw(void** args);
+ static void* SFX_CALL cti_vm_compile(void** args);
+ static JSValue* SFX_CALL cti_op_push_activation(void** args);
#endif // ENABLE(CTI)
void emitConvertToFastCall() {}
#endif
-#if USE(CTI_ARGUMENT)
void emitRestoreArgumentReference()
{
-#if USE(FAST_CALL_CTI_ARGUMENT)
movl_rr(X86::esp, X86::ecx);
-#else
- movl_rm(X86::esp, 0, X86::esp);
-#endif
}
void emitRestoreArgumentReferenceForTrampoline()
{
-#if USE(FAST_CALL_CTI_ARGUMENT)
movl_rr(X86::esp, X86::ecx);
addl_i32r(4, X86::ecx);
-#endif
}
-#else
- void emitRestoreArgumentReference() {}
- void emitRestoreArgumentReferenceForTrampoline() {}
-#endif
private:
void emitModRm_rr(RegisterID reg, RegisterID rm)
#endif
#endif
-// Use "fastcall" calling convention on MSVC and GCC > 4.0
-#if COMPILER(MSVC) || (COMPILER(GCC) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ > 0)))
-#define WTF_USE_FAST_CALL_CTI_ARGUMENT 1
-#endif
-
-#if COMPILER(MSVC) || USE(FAST_CALL_CTI_ARGUMENT)
-#define WTF_USE_CTI_ARGUMENT 1
-#endif
-
#endif /* WTF_Platform_h */