Changeset 39268 in webkit for trunk/JavaScriptCore/jit
- Timestamp:
- Dec 12, 2008, 9:25:22 PM (16 years ago)
- Location:
- trunk/JavaScriptCore/jit
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/jit/JIT.cpp
r39267 r39268 205 205 #define CTI_COMPILE_BINARY_OP(name) \ 206 206 case name: { \ 207 emitPut CTIArgFromVirtualRegister(currentInstruction[2].u.operand, 0, X86::ecx); \208 emitPut CTIArgFromVirtualRegister(currentInstruction[3].u.operand, 4, X86::ecx); \207 emitPutJITStubArgFromVirtualRegister(currentInstruction[2].u.operand, 1, X86::ecx); \ 208 emitPutJITStubArgFromVirtualRegister(currentInstruction[3].u.operand, 2, X86::ecx); \ 209 209 emitCTICall(Interpreter::cti_##name); \ 210 210 emitPutVirtualRegister(currentInstruction[1].u.operand); \ … … 214 214 #define CTI_COMPILE_UNARY_OP(name) \ 215 215 case name: { \ 216 emitPut CTIArgFromVirtualRegister(currentInstruction[2].u.operand, 0, X86::ecx); \216 emitPutJITStubArgFromVirtualRegister(currentInstruction[2].u.operand, 1, X86::ecx); \ 217 217 emitCTICall(Interpreter::cti_##name); \ 218 218 emitPutVirtualRegister(currentInstruction[1].u.operand); \ … … 266 266 compileBinaryArithOp(op_add, currentInstruction[1].u.operand, currentInstruction[2].u.operand, currentInstruction[3].u.operand, OperandTypes::fromInt(currentInstruction[4].u.operand)); 267 267 else { 268 emitPut CTIArgFromVirtualRegister(currentInstruction[2].u.operand, 0, X86::ecx);269 emitPut CTIArgFromVirtualRegister(currentInstruction[3].u.operand, 4, X86::ecx);268 emitPutJITStubArgFromVirtualRegister(currentInstruction[2].u.operand, 1, X86::ecx); 269 emitPutJITStubArgFromVirtualRegister(currentInstruction[3].u.operand, 2, X86::ecx); 270 270 emitCTICall(Interpreter::cti_op_add); 271 271 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 401 401 } 402 402 case op_del_by_id: { 403 emitPut CTIArgFromVirtualRegister(currentInstruction[2].u.operand, 0, X86::ecx);403 emitPutJITStubArgFromVirtualRegister(currentInstruction[2].u.operand, 1, X86::ecx); 404 404 Identifier* ident = &(m_codeBlock->identifier(currentInstruction[3].u.operand)); 405 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 4);405 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 2); 406 406 emitCTICall(Interpreter::cti_op_del_by_id); 407 407 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 438 438 case op_new_func: { 439 439 FuncDeclNode* func = m_codeBlock->function(currentInstruction[2].u.operand); 440 emitPut CTIArgConstant(reinterpret_cast<unsigned>(func), 0);440 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(func), 1); 441 441 emitCTICall(Interpreter::cti_op_new_func); 442 442 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 494 494 } 495 495 case op_tear_off_activation: { 496 emitPut CTIArgFromVirtualRegister(currentInstruction[1].u.operand, 0, X86::ecx);496 emitPutJITStubArgFromVirtualRegister(currentInstruction[1].u.operand, 1, X86::ecx); 497 497 emitCTICall(Interpreter::cti_op_tear_off_activation); 498 498 NEXT_OPCODE(op_tear_off_activation); … … 523 523 } 524 524 case op_new_array: { 525 emitPut CTIArgConstant(currentInstruction[2].u.operand, 0);526 emitPut CTIArgConstant(currentInstruction[3].u.operand, 4);525 emitPutJITStubArgConstant(currentInstruction[2].u.operand, 1); 526 emitPutJITStubArgConstant(currentInstruction[3].u.operand, 2); 527 527 emitCTICall(Interpreter::cti_op_new_array); 528 528 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 531 531 case op_resolve: { 532 532 Identifier* ident = &(m_codeBlock->identifier(currentInstruction[2].u.operand)); 533 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 0);533 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 1); 534 534 emitCTICall(Interpreter::cti_op_resolve); 535 535 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 563 563 case op_resolve_func: { 564 564 Identifier* ident = &(m_codeBlock->identifier(currentInstruction[3].u.operand)); 565 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 0);565 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 1); 566 566 emitCTICall(Interpreter::cti_op_resolve_func); 567 567 emitPutVirtualRegister(currentInstruction[2].u.operand, X86::edx); … … 614 614 case op_resolve_base: { 615 615 Identifier* ident = &(m_codeBlock->identifier(currentInstruction[2].u.operand)); 616 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 0);616 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 1); 617 617 emitCTICall(Interpreter::cti_op_resolve_base); 618 618 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 620 620 } 621 621 case op_negate: { 622 emitPut CTIArgFromVirtualRegister(currentInstruction[2].u.operand, 0, X86::ecx);622 emitPutJITStubArgFromVirtualRegister(currentInstruction[2].u.operand, 1, X86::ecx); 623 623 emitCTICall(Interpreter::cti_op_negate); 624 624 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 627 627 case op_resolve_skip: { 628 628 Identifier* ident = &(m_codeBlock->identifier(currentInstruction[2].u.operand)); 629 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 0);630 emitPut CTIArgConstant(currentInstruction[3].u.operand + m_codeBlock->needsFullScopeChain(), 4);629 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 1); 630 emitPutJITStubArgConstant(currentInstruction[3].u.operand + m_codeBlock->needsFullScopeChain(), 2); 631 631 emitCTICall(Interpreter::cti_op_resolve_skip); 632 632 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 656 656 // Slow case 657 657 noMatch.link(this); 658 emitPut CTIArgConstant(globalObject, 0);659 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 4);660 emitPut CTIArgConstant(currentIndex, 8);658 emitPutJITStubArgConstant(globalObject, 1); 659 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 2); 660 emitPutJITStubArgConstant(currentIndex, 3); 661 661 emitCTICall(Interpreter::cti_op_resolve_global); 662 662 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 848 848 case op_resolve_with_base: { 849 849 Identifier* ident = &(m_codeBlock->identifier(currentInstruction[3].u.operand)); 850 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 0);850 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 1); 851 851 emitCTICall(Interpreter::cti_op_resolve_with_base); 852 852 emitPutVirtualRegister(currentInstruction[2].u.operand, X86::edx); … … 856 856 case op_new_func_exp: { 857 857 FuncExprNode* func = m_codeBlock->functionExpression(currentInstruction[2].u.operand); 858 emitPut CTIArgConstant(reinterpret_cast<unsigned>(func), 0);858 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(func), 1); 859 859 emitCTICall(Interpreter::cti_op_new_func_exp); 860 860 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 919 919 case op_new_regexp: { 920 920 RegExp* regExp = m_codeBlock->regexp(currentInstruction[2].u.operand); 921 emitPut CTIArgConstant(reinterpret_cast<unsigned>(regExp), 0);921 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(regExp), 1); 922 922 emitCTICall(Interpreter::cti_op_new_regexp); 923 923 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 932 932 } 933 933 case op_throw: { 934 emitPut CTIArgFromVirtualRegister(currentInstruction[1].u.operand, 0, X86::ecx);934 emitPutJITStubArgFromVirtualRegister(currentInstruction[1].u.operand, 1, X86::ecx); 935 935 emitCTICall(Interpreter::cti_op_throw); 936 936 __ addl_i8r(0x20, X86::esp); … … 942 942 } 943 943 case op_get_pnames: { 944 emitPut CTIArgFromVirtualRegister(currentInstruction[2].u.operand, 0, X86::ecx);944 emitPutJITStubArgFromVirtualRegister(currentInstruction[2].u.operand, 1, X86::ecx); 945 945 emitCTICall(Interpreter::cti_op_get_pnames); 946 946 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 948 948 } 949 949 case op_next_pname: { 950 emitPut CTIArgFromVirtualRegister(currentInstruction[2].u.operand, 0, X86::ecx);950 emitPutJITStubArgFromVirtualRegister(currentInstruction[2].u.operand, 1, X86::ecx); 951 951 unsigned target = currentInstruction[3].u.operand; 952 952 emitCTICall(Interpreter::cti_op_next_pname); … … 958 958 } 959 959 case op_push_scope: { 960 emitPut CTIArgFromVirtualRegister(currentInstruction[1].u.operand, 0, X86::ecx);960 emitPutJITStubArgFromVirtualRegister(currentInstruction[1].u.operand, 1, X86::ecx); 961 961 emitCTICall(Interpreter::cti_op_push_scope); 962 962 NEXT_OPCODE(op_push_scope); … … 999 999 case op_push_new_scope: { 1000 1000 Identifier* ident = &(m_codeBlock->identifier(currentInstruction[2].u.operand)); 1001 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 0);1002 emitPut CTIArgFromVirtualRegister(currentInstruction[3].u.operand, 4, X86::ecx);1001 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 1); 1002 emitPutJITStubArgFromVirtualRegister(currentInstruction[3].u.operand, 2, X86::ecx); 1003 1003 emitCTICall(Interpreter::cti_op_push_new_scope); 1004 1004 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1012 1012 case op_jmp_scopes: { 1013 1013 unsigned count = currentInstruction[1].u.operand; 1014 emitPut CTIArgConstant(count, 0);1014 emitPutJITStubArgConstant(count, 1); 1015 1015 emitCTICall(Interpreter::cti_op_jmp_scopes); 1016 1016 unsigned target = currentInstruction[2].u.operand; … … 1019 1019 } 1020 1020 case op_put_by_index: { 1021 emitPut CTIArgFromVirtualRegister(currentInstruction[1].u.operand, 0, X86::ecx);1022 emitPut CTIArgConstant(currentInstruction[2].u.operand, 4);1023 emitPut CTIArgFromVirtualRegister(currentInstruction[3].u.operand, 8, X86::ecx);1021 emitPutJITStubArgFromVirtualRegister(currentInstruction[1].u.operand, 1, X86::ecx); 1022 emitPutJITStubArgConstant(currentInstruction[2].u.operand, 2); 1023 emitPutJITStubArgFromVirtualRegister(currentInstruction[3].u.operand, 3, X86::ecx); 1024 1024 emitCTICall(Interpreter::cti_op_put_by_index); 1025 1025 NEXT_OPCODE(op_put_by_index); … … 1035 1035 jumpTable->ctiOffsets.grow(jumpTable->branchOffsets.size()); 1036 1036 1037 emitPut CTIArgFromVirtualRegister(scrutinee, 0, X86::ecx);1038 emitPut CTIArgConstant(tableIndex, 4);1037 emitPutJITStubArgFromVirtualRegister(scrutinee, 1, X86::ecx); 1038 emitPutJITStubArgConstant(tableIndex, 2); 1039 1039 emitCTICall(Interpreter::cti_op_switch_imm); 1040 1040 jump(X86::eax); … … 1051 1051 jumpTable->ctiOffsets.grow(jumpTable->branchOffsets.size()); 1052 1052 1053 emitPut CTIArgFromVirtualRegister(scrutinee, 0, X86::ecx);1054 emitPut CTIArgConstant(tableIndex, 4);1053 emitPutJITStubArgFromVirtualRegister(scrutinee, 1, X86::ecx); 1054 emitPutJITStubArgConstant(tableIndex, 2); 1055 1055 emitCTICall(Interpreter::cti_op_switch_char); 1056 1056 jump(X86::eax); … … 1066 1066 m_switches.append(SwitchRecord(jumpTable, m_bytecodeIndex, defaultOffset)); 1067 1067 1068 emitPut CTIArgFromVirtualRegister(scrutinee, 0, X86::ecx);1069 emitPut CTIArgConstant(tableIndex, 4);1068 emitPutJITStubArgFromVirtualRegister(scrutinee, 1, X86::ecx); 1069 emitPutJITStubArgConstant(tableIndex, 2); 1070 1070 emitCTICall(Interpreter::cti_op_switch_string); 1071 1071 jump(X86::eax); … … 1073 1073 } 1074 1074 case op_del_by_val: { 1075 emitPut CTIArgFromVirtualRegister(currentInstruction[2].u.operand, 0, X86::ecx);1076 emitPut CTIArgFromVirtualRegister(currentInstruction[3].u.operand, 4, X86::ecx);1075 emitPutJITStubArgFromVirtualRegister(currentInstruction[2].u.operand, 1, X86::ecx); 1076 emitPutJITStubArgFromVirtualRegister(currentInstruction[3].u.operand, 2, X86::ecx); 1077 1077 emitCTICall(Interpreter::cti_op_del_by_val); 1078 1078 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1080 1080 } 1081 1081 case op_put_getter: { 1082 emitPut CTIArgFromVirtualRegister(currentInstruction[1].u.operand, 0, X86::ecx);1082 emitPutJITStubArgFromVirtualRegister(currentInstruction[1].u.operand, 1, X86::ecx); 1083 1083 Identifier* ident = &(m_codeBlock->identifier(currentInstruction[2].u.operand)); 1084 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 4);1085 emitPut CTIArgFromVirtualRegister(currentInstruction[3].u.operand, 8, X86::ecx);1084 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 2); 1085 emitPutJITStubArgFromVirtualRegister(currentInstruction[3].u.operand, 3, X86::ecx); 1086 1086 emitCTICall(Interpreter::cti_op_put_getter); 1087 1087 NEXT_OPCODE(op_put_getter); 1088 1088 } 1089 1089 case op_put_setter: { 1090 emitPut CTIArgFromVirtualRegister(currentInstruction[1].u.operand, 0, X86::ecx);1090 emitPutJITStubArgFromVirtualRegister(currentInstruction[1].u.operand, 1, X86::ecx); 1091 1091 Identifier* ident = &(m_codeBlock->identifier(currentInstruction[2].u.operand)); 1092 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 4);1093 emitPut CTIArgFromVirtualRegister(currentInstruction[3].u.operand, 8, X86::ecx);1092 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 2); 1093 emitPutJITStubArgFromVirtualRegister(currentInstruction[3].u.operand, 3, X86::ecx); 1094 1094 emitCTICall(Interpreter::cti_op_put_setter); 1095 1095 NEXT_OPCODE(op_put_setter); … … 1097 1097 case op_new_error: { 1098 1098 JSValue* message = m_codeBlock->unexpectedConstant(currentInstruction[3].u.operand); 1099 emitPut CTIArgConstant(currentInstruction[2].u.operand, 0);1100 emitPut CTIArgConstant(asInteger(message), 4);1101 emitPut CTIArgConstant(m_codeBlock->lineNumberForBytecodeOffset(m_bytecodeIndex), 8);1099 emitPutJITStubArgConstant(currentInstruction[2].u.operand, 1); 1100 emitPutJITStubArgConstant(asInteger(message), 2); 1101 emitPutJITStubArgConstant(m_codeBlock->lineNumberForBytecodeOffset(m_bytecodeIndex), 3); 1102 1102 emitCTICall(Interpreter::cti_op_new_error); 1103 1103 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1105 1105 } 1106 1106 case op_debug: { 1107 emitPut CTIArgConstant(currentInstruction[1].u.operand, 0);1108 emitPut CTIArgConstant(currentInstruction[2].u.operand, 4);1109 emitPut CTIArgConstant(currentInstruction[3].u.operand, 8);1107 emitPutJITStubArgConstant(currentInstruction[1].u.operand, 1); 1108 emitPutJITStubArgConstant(currentInstruction[2].u.operand, 2); 1109 emitPutJITStubArgConstant(currentInstruction[3].u.operand, 3); 1110 1110 emitCTICall(Interpreter::cti_op_debug); 1111 1111 NEXT_OPCODE(op_debug); … … 1202 1202 __ cmpl_i32m(0, X86::eax); 1203 1203 JmpSrc noProfiler = __ je(); 1204 emitPut CTIArgFromVirtualRegister(currentInstruction[1].u.operand, 0, X86::eax);1204 emitPutJITStubArgFromVirtualRegister(currentInstruction[1].u.operand, 1, X86::eax); 1205 1205 emitCTICall(Interpreter::cti_op_profile_will_call); 1206 1206 __ link(noProfiler, __ label()); … … 1212 1212 __ cmpl_i32m(0, X86::eax); 1213 1213 JmpSrc noProfiler = __ je(); 1214 emitPut CTIArgFromVirtualRegister(currentInstruction[1].u.operand, 0, X86::eax);1214 emitPutJITStubArgFromVirtualRegister(currentInstruction[1].u.operand, 1, X86::eax); 1215 1215 emitCTICall(Interpreter::cti_op_profile_did_call); 1216 1216 __ link(noProfiler, __ label()); … … 1271 1271 linkSlowCase(iter); 1272 1272 linkSlowCase(iter); 1273 emitPut CTIArg(X86::eax, 0);1273 emitPutJITStubArg(X86::eax, 1); 1274 1274 emitCTICall(Interpreter::cti_op_convert_this); 1275 1275 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1285 1285 sub32(Imm32(getDeTaggedConstantImmediate(value)), X86::eax); 1286 1286 notImm.link(this); 1287 emitPut CTIArgFromVirtualRegister(src1, 0, X86::ecx);1288 emitPut CTIArg(X86::eax, 4);1287 emitPutJITStubArgFromVirtualRegister(src1, 1, X86::ecx); 1288 emitPutJITStubArg(X86::eax, 2); 1289 1289 emitCTICall(Interpreter::cti_op_add); 1290 1290 emitPutVirtualRegister(dst); … … 1294 1294 sub32(Imm32(getDeTaggedConstantImmediate(value)), X86::eax); 1295 1295 notImm.link(this); 1296 emitPut CTIArg(X86::eax, 0);1297 emitPut CTIArgFromVirtualRegister(src2, 4, X86::ecx);1296 emitPutJITStubArg(X86::eax, 1); 1297 emitPutJITStubArgFromVirtualRegister(src2, 2, X86::ecx); 1298 1298 emitCTICall(Interpreter::cti_op_add); 1299 1299 emitPutVirtualRegister(dst); … … 1323 1323 emitFastArithIntToImmNoCheck(X86::edx); 1324 1324 notImm.link(this); 1325 emitPut CTIArg(X86::eax, 0);1326 emitPut CTIArg(X86::edx, 4);1325 emitPutJITStubArg(X86::eax, 1); 1326 emitPutJITStubArg(X86::edx, 2); 1327 1327 emitCTICall(Interpreter::cti_op_get_by_val); 1328 1328 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1351 1351 linkSlowCase(iter); 1352 1352 if (getConstantImmediateNumericArg(src2)) 1353 emitPut CTIArgFromVirtualRegister(src2, 4, X86::ecx);1353 emitPutJITStubArgFromVirtualRegister(src2, 2, X86::ecx); 1354 1354 else { 1355 1355 linkSlowCase(iter); 1356 emitPut CTIArg(X86::ecx, 4);1356 emitPutJITStubArg(X86::ecx, 2); 1357 1357 } 1358 1358 1359 emitPut CTIArg(X86::eax, 0);1359 emitPutJITStubArg(X86::eax, 1); 1360 1360 emitCTICall(Interpreter::cti_op_rshift); 1361 1361 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1369 1369 notImm1.link(this); 1370 1370 notImm2.link(this); 1371 emitPut CTIArg(X86::eax, 0);1372 emitPut CTIArg(X86::ecx, 4);1371 emitPutJITStubArg(X86::eax, 1); 1372 emitPutJITStubArg(X86::ecx, 2); 1373 1373 emitCTICall(Interpreter::cti_op_lshift); 1374 1374 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1380 1380 if (src2imm) { 1381 1381 linkSlowCase(iter); 1382 emitPut CTIArg(X86::eax, 0);1383 emitPut CTIArgFromVirtualRegister(currentInstruction[2].u.operand, 4, X86::ecx);1382 emitPutJITStubArg(X86::eax, 1); 1383 emitPutJITStubArgFromVirtualRegister(currentInstruction[2].u.operand, 2, X86::ecx); 1384 1384 emitCTICall(Interpreter::cti_op_loop_if_less); 1385 1385 emitJumpSlowToHot(jnz32(X86::eax), target + 3); … … 1387 1387 linkSlowCase(iter); 1388 1388 linkSlowCase(iter); 1389 emitPut CTIArg(X86::eax, 0);1390 emitPut CTIArg(X86::edx, 4);1389 emitPutJITStubArg(X86::eax, 1); 1390 emitPutJITStubArg(X86::edx, 2); 1391 1391 emitCTICall(Interpreter::cti_op_loop_if_less); 1392 1392 emitJumpSlowToHot(jnz32(X86::eax), target + 3); … … 1407 1407 if (src2imm) { 1408 1408 linkSlowCase(iter); 1409 emitPut CTIArg(X86::eax, 0);1410 emitPut CTIArgFromVirtualRegister(currentInstruction[2].u.operand, 4, X86::ecx);1409 emitPutJITStubArg(X86::eax, 1); 1410 emitPutJITStubArgFromVirtualRegister(currentInstruction[2].u.operand, 2, X86::ecx); 1411 1411 emitCTICall(Interpreter::cti_op_loop_if_lesseq); 1412 1412 emitJumpSlowToHot(jnz32(X86::eax), target + 3); … … 1414 1414 linkSlowCase(iter); 1415 1415 linkSlowCase(iter); 1416 emitPut CTIArg(X86::eax, 0);1417 emitPut CTIArg(X86::edx, 4);1416 emitPutJITStubArg(X86::eax, 1); 1417 emitPutJITStubArg(X86::edx, 2); 1418 1418 emitCTICall(Interpreter::cti_op_loop_if_lesseq); 1419 1419 emitJumpSlowToHot(jnz32(X86::eax), target + 3); … … 1427 1427 sub32(Imm32(getDeTaggedConstantImmediate(JSImmediate::oneImmediate())), X86::eax); 1428 1428 notImm.link(this); 1429 emitPut CTIArg(X86::eax, 0);1429 emitPutJITStubArg(X86::eax, 1); 1430 1430 emitCTICall(Interpreter::cti_op_pre_inc); 1431 1431 emitPutVirtualRegister(srcDst); … … 1440 1440 notImm.link(this); 1441 1441 emitGetVirtualRegister(currentInstruction[3].u.operand, X86::ecx); 1442 emitPut CTIArg(X86::eax, 0);1443 emitPut CTIArg(X86::edx, 4);1444 emitPut CTIArg(X86::ecx, 8);1442 emitPutJITStubArg(X86::eax, 1); 1443 emitPutJITStubArg(X86::edx, 2); 1444 emitPutJITStubArg(X86::ecx, 3); 1445 1445 emitCTICall(Interpreter::cti_op_put_by_val); 1446 1446 emitJumpSlowToHot(jump(), OPCODE_LENGTH(op_put_by_val)); … … 1450 1450 linkSlowCase(iter); 1451 1451 emitGetVirtualRegister(currentInstruction[3].u.operand, X86::ecx); 1452 emitPut CTIArg(X86::eax, 0);1453 emitPut CTIArg(X86::edx, 4);1454 emitPut CTIArg(X86::ecx, 8);1452 emitPutJITStubArg(X86::eax, 1); 1453 emitPutJITStubArg(X86::edx, 2); 1454 emitPutJITStubArg(X86::ecx, 3); 1455 1455 emitCTICall(Interpreter::cti_op_put_by_val_array); 1456 1456 … … 1459 1459 case op_loop_if_true: { 1460 1460 linkSlowCase(iter); 1461 emitPut CTIArg(X86::eax, 0);1461 emitPutJITStubArg(X86::eax, 1); 1462 1462 emitCTICall(Interpreter::cti_op_jtrue); 1463 1463 unsigned target = currentInstruction[2].u.operand; … … 1471 1471 add32(Imm32(getDeTaggedConstantImmediate(JSImmediate::oneImmediate())), X86::eax); 1472 1472 notImm.link(this); 1473 emitPut CTIArg(X86::eax, 0);1473 emitPutJITStubArg(X86::eax, 1); 1474 1474 emitCTICall(Interpreter::cti_op_pre_dec); 1475 1475 emitPutVirtualRegister(srcDst); … … 1481 1481 if (src2imm) { 1482 1482 linkSlowCase(iter); 1483 emitPut CTIArg(X86::edx, 0);1484 emitPut CTIArgFromVirtualRegister(currentInstruction[2].u.operand, 4, X86::ecx);1483 emitPutJITStubArg(X86::edx, 1); 1484 emitPutJITStubArgFromVirtualRegister(currentInstruction[2].u.operand, 2, X86::ecx); 1485 1485 emitCTICall(Interpreter::cti_op_jless); 1486 1486 emitJumpSlowToHot(jz32(X86::eax), target + 3); … … 1488 1488 linkSlowCase(iter); 1489 1489 linkSlowCase(iter); 1490 emitPut CTIArg(X86::eax, 0);1491 emitPut CTIArg(X86::edx, 4);1490 emitPutJITStubArg(X86::eax, 1); 1491 emitPutJITStubArg(X86::edx, 2); 1492 1492 emitCTICall(Interpreter::cti_op_jless); 1493 1493 emitJumpSlowToHot(jz32(X86::eax), target + 3); … … 1498 1498 linkSlowCase(iter); 1499 1499 xor32(Imm32(JSImmediate::FullTagTypeBool), X86::eax); 1500 emitPut CTIArg(X86::eax, 0);1500 emitPutJITStubArg(X86::eax, 1); 1501 1501 emitCTICall(Interpreter::cti_op_not); 1502 1502 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1505 1505 case op_jfalse: { 1506 1506 linkSlowCase(iter); 1507 emitPut CTIArg(X86::eax, 0);1507 emitPutJITStubArg(X86::eax, 1); 1508 1508 emitCTICall(Interpreter::cti_op_jtrue); 1509 1509 unsigned target = currentInstruction[2].u.operand; … … 1515 1515 linkSlowCase(iter); 1516 1516 linkSlowCase(iter); 1517 emitPut CTIArg(X86::eax, 0);1517 emitPutJITStubArg(X86::eax, 1); 1518 1518 emitCTICall(Interpreter::cti_op_post_inc); 1519 1519 emitPutVirtualRegister(srcDst, X86::edx); … … 1523 1523 case op_bitnot: { 1524 1524 linkSlowCase(iter); 1525 emitPut CTIArg(X86::eax, 0);1525 emitPutJITStubArg(X86::eax, 1); 1526 1526 emitCTICall(Interpreter::cti_op_bitnot); 1527 1527 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1534 1534 unsigned dst = currentInstruction[1].u.operand; 1535 1535 if (getConstantImmediateNumericArg(src1)) { 1536 emitPut CTIArgFromVirtualRegister(src1, 0, X86::ecx);1537 emitPut CTIArg(X86::eax, 4);1536 emitPutJITStubArgFromVirtualRegister(src1, 1, X86::ecx); 1537 emitPutJITStubArg(X86::eax, 2); 1538 1538 emitCTICall(Interpreter::cti_op_bitand); 1539 1539 emitPutVirtualRegister(dst); 1540 1540 } else if (getConstantImmediateNumericArg(src2)) { 1541 emitPut CTIArg(X86::eax, 0);1542 emitPut CTIArgFromVirtualRegister(src2, 4, X86::ecx);1541 emitPutJITStubArg(X86::eax, 1); 1542 emitPutJITStubArgFromVirtualRegister(src2, 2, X86::ecx); 1543 1543 emitCTICall(Interpreter::cti_op_bitand); 1544 1544 emitPutVirtualRegister(dst); 1545 1545 } else { 1546 emitPut CTIArgFromVirtualRegister(src1, 0, X86::ecx);1547 emitPut CTIArg(X86::edx, 4);1546 emitPutJITStubArgFromVirtualRegister(src1, 1, X86::ecx); 1547 emitPutJITStubArg(X86::edx, 2); 1548 1548 emitCTICall(Interpreter::cti_op_bitand); 1549 1549 emitPutVirtualRegister(dst); … … 1553 1553 case op_jtrue: { 1554 1554 linkSlowCase(iter); 1555 emitPut CTIArg(X86::eax, 0);1555 emitPutJITStubArg(X86::eax, 1); 1556 1556 emitCTICall(Interpreter::cti_op_jtrue); 1557 1557 unsigned target = currentInstruction[2].u.operand; … … 1563 1563 linkSlowCase(iter); 1564 1564 linkSlowCase(iter); 1565 emitPut CTIArg(X86::eax, 0);1565 emitPutJITStubArg(X86::eax, 1); 1566 1566 emitCTICall(Interpreter::cti_op_post_dec); 1567 1567 emitPutVirtualRegister(srcDst, X86::edx); … … 1571 1571 case op_bitxor: { 1572 1572 linkSlowCase(iter); 1573 emitPut CTIArg(X86::eax, 0);1574 emitPut CTIArg(X86::edx, 4);1573 emitPutJITStubArg(X86::eax, 1); 1574 emitPutJITStubArg(X86::edx, 2); 1575 1575 emitCTICall(Interpreter::cti_op_bitxor); 1576 1576 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1579 1579 case op_bitor: { 1580 1580 linkSlowCase(iter); 1581 emitPut CTIArg(X86::eax, 0);1582 emitPut CTIArg(X86::edx, 4);1581 emitPutJITStubArg(X86::eax, 1); 1582 emitPutJITStubArg(X86::edx, 2); 1583 1583 emitCTICall(Interpreter::cti_op_bitor); 1584 1584 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1587 1587 case op_eq: { 1588 1588 linkSlowCase(iter); 1589 emitPut CTIArg(X86::eax, 0);1590 emitPut CTIArg(X86::edx, 4);1589 emitPutJITStubArg(X86::eax, 1); 1590 emitPutJITStubArg(X86::edx, 2); 1591 1591 emitCTICall(Interpreter::cti_op_eq); 1592 1592 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1595 1595 case op_neq: { 1596 1596 linkSlowCase(iter); 1597 emitPut CTIArg(X86::eax, 0);1598 emitPut CTIArg(X86::edx, 4);1597 emitPutJITStubArg(X86::eax, 1); 1598 emitPutJITStubArg(X86::edx, 2); 1599 1599 emitCTICall(Interpreter::cti_op_neq); 1600 1600 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1605 1605 linkSlowCase(iter); 1606 1606 linkSlowCase(iter); 1607 emitPut CTIArg(X86::eax, 0);1608 emitPut CTIArg(X86::edx, 4);1607 emitPutJITStubArg(X86::eax, 1); 1608 emitPutJITStubArg(X86::edx, 2); 1609 1609 emitCTICall(Interpreter::cti_op_stricteq); 1610 1610 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1615 1615 linkSlowCase(iter); 1616 1616 linkSlowCase(iter); 1617 emitPut CTIArg(X86::eax, 0);1618 emitPut CTIArg(X86::edx, 4);1617 emitPutJITStubArg(X86::eax, 1); 1618 emitPutJITStubArg(X86::edx, 2); 1619 1619 emitCTICall(Interpreter::cti_op_nstricteq); 1620 1620 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1625 1625 linkSlowCase(iter); 1626 1626 linkSlowCase(iter); 1627 emitPut CTIArgFromVirtualRegister(currentInstruction[2].u.operand, 0, X86::ecx);1628 emitPut CTIArgFromVirtualRegister(currentInstruction[3].u.operand, 4, X86::ecx);1629 emitPut CTIArgFromVirtualRegister(currentInstruction[4].u.operand, 8, X86::ecx);1627 emitPutJITStubArgFromVirtualRegister(currentInstruction[2].u.operand, 1, X86::ecx); 1628 emitPutJITStubArgFromVirtualRegister(currentInstruction[3].u.operand, 2, X86::ecx); 1629 emitPutJITStubArgFromVirtualRegister(currentInstruction[4].u.operand, 3, X86::ecx); 1630 1630 emitCTICall(Interpreter::cti_op_instanceof); 1631 1631 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1640 1640 notImm1.link(this); 1641 1641 notImm2.link(this); 1642 emitPut CTIArg(X86::eax, 0);1643 emitPut CTIArg(X86::ecx, 4);1642 emitPutJITStubArg(X86::eax, 1); 1643 emitPutJITStubArg(X86::ecx, 2); 1644 1644 emitCTICall(Interpreter::cti_op_mod); 1645 1645 emitPutVirtualRegister(currentInstruction[1].u.operand); … … 1657 1657 linkSlowCase(iter); 1658 1658 // There is an extra slow case for (op1 * -N) or (-N * op2), to check for 0 since this should produce a result of -0. 1659 emitPut CTIArgFromVirtualRegister(src1, 0, X86::ecx);1660 emitPut CTIArgFromVirtualRegister(src2, 4, X86::ecx);1659 emitPutJITStubArgFromVirtualRegister(src1, 1, X86::ecx); 1660 emitPutJITStubArgFromVirtualRegister(src2, 2, X86::ecx); 1661 1661 emitCTICall(Interpreter::cti_op_mul); 1662 1662 emitPutVirtualRegister(dst); … … 1665 1665 linkSlowCase(iter); 1666 1666 // There is an extra slow case for (op1 * -N) or (-N * op2), to check for 0 since this should produce a result of -0. 1667 emitPut CTIArgFromVirtualRegister(src1, 0, X86::ecx);1668 emitPut CTIArgFromVirtualRegister(src2, 4, X86::ecx);1667 emitPutJITStubArgFromVirtualRegister(src1, 1, X86::ecx); 1668 emitPutJITStubArgFromVirtualRegister(src2, 2, X86::ecx); 1669 1669 emitCTICall(Interpreter::cti_op_mul); 1670 1670 emitPutVirtualRegister(dst); … … 1690 1690 linkSlowCase(iter); 1691 1691 1692 emitPut CTIArg(X86::eax, 0);1692 emitPutJITStubArg(X86::eax, 1); 1693 1693 emitCTICall(Interpreter::cti_op_to_jsnumber); 1694 1694 … … 1878 1878 emitPutCTIParam(X86::edi, CTI_ARGS_callFrame); 1879 1879 JmpSrc callJSFunction1 = __ call(); 1880 emitGet CTIArg(0, X86::ecx);1881 emitGet CTIArg(8, X86::edx);1880 emitGetJITStubArg(1, X86::ecx); 1881 emitGetJITStubArg(3, X86::edx); 1882 1882 __ pushl_r(X86::ebx); 1883 1883 __ link(hasCodeBlock1, __ label()); … … 1887 1887 JmpSrc arityCheckOkay1 = __ je(); 1888 1888 __ popl_r(X86::ebx); 1889 emitPut CTIArg(X86::ebx, 4);1890 emitPut CTIArg(X86::eax, 12);1889 emitPutJITStubArg(X86::ebx, 2); 1890 emitPutJITStubArg(X86::eax, 4); 1891 1891 emitPutCTIParam(X86::edi, CTI_ARGS_callFrame); 1892 1892 JmpSrc callArityCheck1 = __ call(); 1893 1893 __ movl_rr(X86::edx, X86::edi); 1894 emitGet CTIArg(0, X86::ecx);1895 emitGet CTIArg(8, X86::edx);1894 emitGetJITStubArg(1, X86::ecx); 1895 emitGetJITStubArg(3, X86::edx); 1896 1896 __ pushl_r(X86::ebx); 1897 1897 __ link(arityCheckOkay1, __ label()); … … 1900 1900 1901 1901 __ popl_r(X86::ebx); 1902 emitPut CTIArg(X86::ebx, 4);1902 emitPutJITStubArg(X86::ebx, 2); 1903 1903 emitPutCTIParam(X86::edi, CTI_ARGS_callFrame); 1904 1904 JmpSrc callDontLazyLinkCall = __ call(); … … 1917 1917 emitPutCTIParam(X86::edi, CTI_ARGS_callFrame); 1918 1918 JmpSrc callJSFunction2 = __ call(); 1919 emitGet CTIArg(0, X86::ecx);1920 emitGet CTIArg(8, X86::edx);1919 emitGetJITStubArg(1, X86::ecx); 1920 emitGetJITStubArg(3, X86::edx); 1921 1921 __ pushl_r(X86::ebx); 1922 1922 __ link(hasCodeBlock2, __ label()); … … 1926 1926 JmpSrc arityCheckOkay2 = __ je(); 1927 1927 __ popl_r(X86::ebx); 1928 emitPut CTIArg(X86::ebx, 4);1929 emitPut CTIArg(X86::eax, 12);1928 emitPutJITStubArg(X86::ebx, 2); 1929 emitPutJITStubArg(X86::eax, 4); 1930 1930 emitPutCTIParam(X86::edi, CTI_ARGS_callFrame); 1931 1931 JmpSrc callArityCheck2 = __ call(); 1932 1932 __ movl_rr(X86::edx, X86::edi); 1933 emitGet CTIArg(0, X86::ecx);1934 emitGet CTIArg(8, X86::edx);1933 emitGetJITStubArg(1, X86::ecx); 1934 emitGetJITStubArg(3, X86::edx); 1935 1935 __ pushl_r(X86::ebx); 1936 1936 __ link(arityCheckOkay2, __ label()); … … 1939 1939 1940 1940 __ popl_r(X86::ebx); 1941 emitPut CTIArg(X86::ebx, 4);1941 emitPutJITStubArg(X86::ebx, 2); 1942 1942 emitPutCTIParam(X86::edi, CTI_ARGS_callFrame); 1943 1943 JmpSrc callLazyLinkCall = __ call(); … … 1956 1956 emitPutCTIParam(X86::edi, CTI_ARGS_callFrame); 1957 1957 JmpSrc callJSFunction3 = __ call(); 1958 emitGet CTIArg(0, X86::ecx);1959 emitGet CTIArg(8, X86::edx);1958 emitGetJITStubArg(1, X86::ecx); 1959 emitGetJITStubArg(3, X86::edx); 1960 1960 __ pushl_r(X86::ebx); 1961 1961 __ link(hasCodeBlock3, __ label()); … … 1965 1965 JmpSrc arityCheckOkay3 = __ je(); 1966 1966 __ popl_r(X86::ebx); 1967 emitPut CTIArg(X86::ebx, 4);1968 emitPut CTIArg(X86::eax, 12);1967 emitPutJITStubArg(X86::ebx, 2); 1968 emitPutJITStubArg(X86::eax, 4); 1969 1969 emitPutCTIParam(X86::edi, CTI_ARGS_callFrame); 1970 1970 JmpSrc callArityCheck3 = __ call(); 1971 1971 __ movl_rr(X86::edx, X86::edi); 1972 emitGet CTIArg(0, X86::ecx);1973 emitGet CTIArg(8, X86::edx);1972 emitGetJITStubArg(1, X86::ecx); 1973 emitGetJITStubArg(3, X86::edx); 1974 1974 __ pushl_r(X86::ebx); 1975 1975 __ link(arityCheckOkay3, __ label()); -
trunk/JavaScriptCore/jit/JIT.h
r39266 r39268 354 354 void emitPutVirtualRegister(unsigned dst, RegisterID from = X86::eax); 355 355 356 void emitPut CTIArg(RegisterID src, unsigned offset);357 void emitPut CTIArgFromVirtualRegister(unsigned src, unsigned offset, RegisterID scratch);358 void emitPut CTIArgConstant(unsigned value, unsigned offset);359 void emitPut CTIArgConstant(void* value, unsigned offset);360 void emitGet CTIArg(unsigned offset, RegisterID dst);356 void emitPutJITStubArg(RegisterID src, unsigned argumentNumber); 357 void emitPutJITStubArgFromVirtualRegister(unsigned src, unsigned argumentNumber, RegisterID scratch); 358 void emitPutJITStubArgConstant(unsigned value, unsigned argumentNumber); 359 void emitPutJITStubArgConstant(void* value, unsigned argumentNumber); 360 void emitGetJITStubArg(unsigned argumentNumber, RegisterID dst); 361 361 362 362 void emitInitRegister(unsigned dst); -
trunk/JavaScriptCore/jit/JITArithmetic.cpp
r39266 r39268 49 49 void JIT::compileBinaryArithOp(OpcodeID opcodeID, unsigned dst, unsigned src1, unsigned src2, OperandTypes) 50 50 { 51 emitPut CTIArgFromVirtualRegister(src1, 0, X86::ecx);52 emitPut CTIArgFromVirtualRegister(src2, 4, X86::ecx);51 emitPutJITStubArgFromVirtualRegister(src1, 1, X86::ecx); 52 emitPutJITStubArgFromVirtualRegister(src2, 2, X86::ecx); 53 53 if (opcodeID == op_add) 54 54 emitCTICall(Interpreter::cti_op_add); … … 324 324 linkSlowCase(iter); 325 325 326 emitPut CTIArgFromVirtualRegister(src1, 0, X86::ecx);327 emitPut CTIArgFromVirtualRegister(src2, 4, X86::ecx);326 emitPutJITStubArgFromVirtualRegister(src1, 1, X86::ecx); 327 emitPutJITStubArgFromVirtualRegister(src2, 2, X86::ecx); 328 328 if (opcodeID == op_add) 329 329 emitCTICall(Interpreter::cti_op_add); -
trunk/JavaScriptCore/jit/JITCall.cpp
r39266 r39268 87 87 88 88 // ecx holds func 89 emitPut CTIArg(X86::ecx, 0);90 emitPut CTIArgConstant(registerOffset, 4);91 emitPut CTIArgConstant(argCount, 8);92 emitPut CTIArgConstant(reinterpret_cast<unsigned>(instruction), 12);89 emitPutJITStubArg(X86::ecx, 1); 90 emitPutJITStubArgConstant(registerOffset, 2); 91 emitPutJITStubArgConstant(argCount, 3); 92 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(instruction), 4); 93 93 } 94 94 … … 99 99 100 100 // ecx holds func 101 emitPut CTIArg(X86::ecx, 0);102 emitPut CTIArgConstant(registerOffset, 4);103 emitPut CTIArgConstant(argCount, 8);101 emitPutJITStubArg(X86::ecx, 1); 102 emitPutJITStubArgConstant(registerOffset, 2); 103 emitPutJITStubArgConstant(argCount, 3); 104 104 } 105 105 … … 112 112 113 113 // ecx holds func 114 emitPut CTIArg(X86::ecx, 0);115 emitPut CTIArgConstant(registerOffset, 4);116 emitPut CTIArgConstant(argCount, 8);117 emitPut CTIArgFromVirtualRegister(proto, 12, X86::eax);118 emitPut CTIArgConstant(thisRegister, 16);114 emitPutJITStubArg(X86::ecx, 1); 115 emitPutJITStubArgConstant(registerOffset, 2); 116 emitPutJITStubArgConstant(argCount, 3); 117 emitPutJITStubArgFromVirtualRegister(proto, 4, X86::eax); 118 emitPutJITStubArgConstant(thisRegister, 5); 119 119 } 120 120 … … 233 233 int thisRegister = instruction[6].u.operand; 234 234 235 emitPut CTIArg(X86::ecx, 0);236 emitPut CTIArgFromVirtualRegister(proto, 12, X86::eax);235 emitPutJITStubArg(X86::ecx, 1); 236 emitPutJITStubArgFromVirtualRegister(proto, 4, X86::eax); 237 237 emitCTICall(Interpreter::cti_op_construct_JSConstruct); 238 238 emitPutVirtualRegister(thisRegister); -
trunk/JavaScriptCore/jit/JITInlineMethods.h
r39266 r39268 102 102 103 103 // puts an arg onto the stack, as an arg to a context threaded function. 104 ALWAYS_INLINE void JIT::emitPut CTIArg(RegisterID src, unsigned offset)105 { 106 poke(src, (offset / sizeof(void*)) + 1);107 } 108 109 ALWAYS_INLINE void JIT::emitPut CTIArgConstant(unsigned value, unsigned offset)110 { 111 poke(Imm32(value), (offset / sizeof(void*)) + 1);112 } 113 114 ALWAYS_INLINE void JIT::emitPut CTIArgConstant(void* value, unsigned offset)115 { 116 poke(ImmPtr(value), (offset / sizeof(void*)) + 1);117 } 118 119 ALWAYS_INLINE void JIT::emitGet CTIArg(unsigned offset, RegisterID dst)120 { 121 peek(dst, (offset / sizeof(void*)) + 1);104 ALWAYS_INLINE void JIT::emitPutJITStubArg(RegisterID src, unsigned argumentNumber) 105 { 106 poke(src, argumentNumber); 107 } 108 109 ALWAYS_INLINE void JIT::emitPutJITStubArgConstant(unsigned value, unsigned argumentNumber) 110 { 111 poke(Imm32(value), argumentNumber); 112 } 113 114 ALWAYS_INLINE void JIT::emitPutJITStubArgConstant(void* value, unsigned argumentNumber) 115 { 116 poke(ImmPtr(value), argumentNumber); 117 } 118 119 ALWAYS_INLINE void JIT::emitGetJITStubArg(unsigned argumentNumber, RegisterID dst) 120 { 121 peek(dst, argumentNumber); 122 122 } 123 123 … … 132 132 133 133 // get arg puts an arg from the SF register array onto the stack, as an arg to a context threaded function. 134 ALWAYS_INLINE void JIT::emitPut CTIArgFromVirtualRegister(unsigned src, unsigned offset, RegisterID scratch)134 ALWAYS_INLINE void JIT::emitPutJITStubArgFromVirtualRegister(unsigned src, unsigned argumentNumber, RegisterID scratch) 135 135 { 136 136 if (m_codeBlock->isConstantRegisterIndex(src)) { 137 137 JSValue* value = m_codeBlock->getConstant(src); 138 emitPut CTIArgConstant(value, offset);138 emitPutJITStubArgConstant(value, argumentNumber); 139 139 } else { 140 140 loadPtr(Address(callFrameRegister, src * sizeof(Register)), scratch); 141 emitPut CTIArg(scratch, offset);141 emitPutJITStubArg(scratch, argumentNumber); 142 142 } 143 143 -
trunk/JavaScriptCore/jit/JITPropertyAccess.cpp
r39266 r39268 56 56 emitGetVirtualRegister(baseVReg, X86::eax); 57 57 58 emitPut CTIArg(X86::eax, 0);59 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 4);58 emitPutJITStubArg(X86::eax, 1); 59 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 2); 60 60 emitCTICall(Interpreter::cti_op_get_by_id_generic); 61 61 emitPutVirtualRegister(resultVReg); … … 76 76 emitGetVirtualRegisters(baseVReg, X86::eax, valueVReg, X86::edx); 77 77 78 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 4);79 emitPut CTIArg(X86::eax, 0);80 emitPut CTIArg(X86::edx, 8);78 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 2); 79 emitPutJITStubArg(X86::eax, 1); 80 emitPutJITStubArg(X86::edx, 3); 81 81 emitCTICall(Interpreter::cti_op_put_by_id_generic); 82 82 } … … 129 129 JmpDst coldPathBegin = __ label(); 130 130 #endif 131 emitPut CTIArg(X86::eax, 0);132 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 4);131 emitPutJITStubArg(X86::eax, 1); 132 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 2); 133 133 JmpSrc call = emitCTICall(Interpreter::cti_op_get_by_id); 134 134 ASSERT(X86Assembler::getDifferenceBetweenLabels(coldPathBegin, call) == repatchOffsetGetByIdSlowCaseCall); … … 169 169 linkSlowCase(iter); 170 170 171 emitPut CTIArgConstant(reinterpret_cast<unsigned>(ident), 4);172 emitPut CTIArg(X86::eax, 0);173 emitPut CTIArg(X86::edx, 8);171 emitPutJITStubArgConstant(reinterpret_cast<unsigned>(ident), 2); 172 emitPutJITStubArg(X86::eax, 1); 173 emitPutJITStubArg(X86::edx, 3); 174 174 JmpSrc call = emitCTICall(Interpreter::cti_op_put_by_id); 175 175
Note:
See TracChangeset
for help on using the changeset viewer.