Changeset 96175 in webkit
- Timestamp:
- Sep 27, 2011 6:09:33 PM (13 years ago)
- Location:
- trunk/Source/JavaScriptCore
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r96171 r96175 1 2011-09-27 Gavin Barraclough <barraclough@apple.com> 2 3 Get JSVALUE32_64 DFG JIT building on OS X. 4 https://bugs.webkit.org/show_bug.cgi?id=68961 5 6 Reviewed by Geoff Garen. 7 8 * Merge bug #68763 (DFG JIT should not eagerly initialize integer tags in the register file). 9 * Forward-declare functions in DFGOperations.cpp 10 * UNUSED_PARAM for unused arguments 11 * NO_RETURN for unimplemented function that ASSERT_NOT_REACHED 12 * Fix argument types handled by OpInfo constructor. 13 * Use SYMBOL_STRING instead of STRINGIZE for asm symbols. 14 * Add files to Xcode project. 15 1 16 2011-09-27 Yuqiang Xian <yuqiang.xian@intel.com> 2 17 -
trunk/Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj
r95895 r96175 297 297 86704B8912DBA33700A9FE7B /* YarrPattern.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 86704B8212DBA33700A9FE7B /* YarrPattern.cpp */; }; 298 298 86704B8A12DBA33700A9FE7B /* YarrPattern.h in Headers */ = {isa = PBXBuildFile; fileRef = 86704B8312DBA33700A9FE7B /* YarrPattern.h */; settings = {ATTRIBUTES = (Private, ); }; }; 299 86880F1C14328BB900B08D42 /* DFGJITCodeGenerator32_64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 86880F1814328BB900B08D42 /* DFGJITCodeGenerator32_64.cpp */; }; 300 86880F1D14328BB900B08D42 /* DFGJITCompiler32_64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 86880F1914328BB900B08D42 /* DFGJITCompiler32_64.cpp */; }; 301 86880F1E14328BB900B08D42 /* DFGJITCompilerInlineMethods.h in Headers */ = {isa = PBXBuildFile; fileRef = 86880F1A14328BB900B08D42 /* DFGJITCompilerInlineMethods.h */; }; 302 86880F1F14328BB900B08D42 /* DFGSpeculativeJIT32_64.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 86880F1B14328BB900B08D42 /* DFGSpeculativeJIT32_64.cpp */; }; 299 303 868BFA08117CEFD100B908B1 /* AtomicString.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 868BFA00117CEFD100B908B1 /* AtomicString.cpp */; }; 300 304 868BFA09117CEFD100B908B1 /* AtomicString.h in Headers */ = {isa = PBXBuildFile; fileRef = 868BFA01117CEFD100B908B1 /* AtomicString.h */; settings = {ATTRIBUTES = (Private, ); }; }; … … 1055 1059 867FC35F11B763950025105E /* JavaScriptCore.JSVALUE32_64only.exp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.exports; path = JavaScriptCore.JSVALUE32_64only.exp; sourceTree = "<group>"; }; 1056 1060 867FC36111B763950025105E /* JavaScriptCore.JSVALUE64only.exp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.exports; path = JavaScriptCore.JSVALUE64only.exp; sourceTree = "<group>"; }; 1061 86880F1814328BB900B08D42 /* DFGJITCodeGenerator32_64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGJITCodeGenerator32_64.cpp; path = dfg/DFGJITCodeGenerator32_64.cpp; sourceTree = "<group>"; }; 1062 86880F1914328BB900B08D42 /* DFGJITCompiler32_64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGJITCompiler32_64.cpp; path = dfg/DFGJITCompiler32_64.cpp; sourceTree = "<group>"; }; 1063 86880F1A14328BB900B08D42 /* DFGJITCompilerInlineMethods.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DFGJITCompilerInlineMethods.h; path = dfg/DFGJITCompilerInlineMethods.h; sourceTree = "<group>"; }; 1064 86880F1B14328BB900B08D42 /* DFGSpeculativeJIT32_64.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DFGSpeculativeJIT32_64.cpp; path = dfg/DFGSpeculativeJIT32_64.cpp; sourceTree = "<group>"; }; 1057 1065 868BFA00117CEFD100B908B1 /* AtomicString.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = AtomicString.cpp; path = text/AtomicString.cpp; sourceTree = "<group>"; }; 1058 1066 868BFA01117CEFD100B908B1 /* AtomicString.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AtomicString.h; path = text/AtomicString.h; sourceTree = "<group>"; }; … … 2248 2256 isa = PBXGroup; 2249 2257 children = ( 2250 0FD82EF31423073900179C94 /* DFGIntrinsic.h */, 2251 0FD82E52141DAEDE00179C94 /* DFGOSREntry.cpp */, 2252 0FD82E53141DAEDE00179C94 /* DFGOSREntry.h */, 2258 86EC9DB41328DF82002B2AD7 /* DFGByteCodeParser.cpp */, 2259 86EC9DB51328DF82002B2AD7 /* DFGByteCodeParser.h */, 2253 2260 0FD82E1E14172C2F00179C94 /* DFGCapabilities.cpp */, 2254 2261 0FD82E1F14172C2F00179C94 /* DFGCapabilities.h */, 2255 0FD3C82414115D2200FD81CB /* DFGPropagator.h */,2256 0FD3C82314115D1A00FD81CB /* DFGPropagator.cpp */,2257 2262 0FD3C82214115D0E00FD81CB /* DFGDriver.h */, 2258 2263 0FD3C82014115CF800FD81CB /* DFGDriver.cpp */, 2259 86EC9DB41328DF82002B2AD7 /* DFGByteCodeParser.cpp */,2260 86EC9DB51328DF82002B2AD7 /* DFGByteCodeParser.h */,2261 2264 86AE6C4B136A11E400963012 /* DFGFPRInfo.h */, 2262 2265 86EC9DB61328DF82002B2AD7 /* DFGGenerationInfo.h */, 2263 2266 86AE6C4C136A11E400963012 /* DFGGPRInfo.h */, 2264 2267 86EC9DB71328DF82002B2AD7 /* DFGGraph.cpp */, 2268 0FD82EF31423073900179C94 /* DFGIntrinsic.h */, 2265 2269 86EC9DB81328DF82002B2AD7 /* DFGGraph.h */, 2266 2270 86EC9DB91328DF82002B2AD7 /* DFGJITCodeGenerator.cpp */, 2267 2271 86EC9DBA1328DF82002B2AD7 /* DFGJITCodeGenerator.h */, 2272 86880F1814328BB900B08D42 /* DFGJITCodeGenerator32_64.cpp */, 2268 2273 86EC9DBB1328DF82002B2AD7 /* DFGJITCompiler.cpp */, 2269 2274 86EC9DBC1328DF82002B2AD7 /* DFGJITCompiler.h */, 2275 86880F1914328BB900B08D42 /* DFGJITCompiler32_64.cpp */, 2276 86880F1A14328BB900B08D42 /* DFGJITCompilerInlineMethods.h */, 2270 2277 86ECA3E9132DEF1C002B2AD7 /* DFGNode.h */, 2278 0FD82E52141DAEDE00179C94 /* DFGOSREntry.cpp */, 2279 0FD82E53141DAEDE00179C94 /* DFGOSREntry.h */, 2271 2280 86EC9DBF1328DF82002B2AD7 /* DFGOperations.cpp */, 2272 2281 86EC9DC01328DF82002B2AD7 /* DFGOperations.h */, 2282 0FD3C82414115D2200FD81CB /* DFGPropagator.h */, 2283 0FD3C82314115D1A00FD81CB /* DFGPropagator.cpp */, 2273 2284 86EC9DC11328DF82002B2AD7 /* DFGRegisterBank.h */, 2274 2285 86BB09BE138E381B0056702F /* DFGRepatch.cpp */, … … 2277 2288 86EC9DC21328DF82002B2AD7 /* DFGSpeculativeJIT.cpp */, 2278 2289 86EC9DC31328DF82002B2AD7 /* DFGSpeculativeJIT.h */, 2290 86880F1B14328BB900B08D42 /* DFGSpeculativeJIT32_64.cpp */, 2279 2291 ); 2280 2292 name = dfg; … … 2826 2838 86FA9E92142BBB2E001773B7 /* JSBoundFunction.h in Headers */, 2827 2839 A7521E131429169A003C8D0C /* CardSet.h in Headers */, 2840 86880F1E14328BB900B08D42 /* DFGJITCompilerInlineMethods.h in Headers */, 2828 2841 ); 2829 2842 runOnlyForDeploymentPostprocessing = 0; … … 3351 3364 86FA9E91142BBB2E001773B7 /* JSBoundFunction.cpp in Sources */, 3352 3365 0F604E8B142D696D009CEB92 /* BitVector.cpp in Sources */, 3366 86880F1C14328BB900B08D42 /* DFGJITCodeGenerator32_64.cpp in Sources */, 3367 86880F1D14328BB900B08D42 /* DFGJITCompiler32_64.cpp in Sources */, 3368 86880F1F14328BB900B08D42 /* DFGSpeculativeJIT32_64.cpp in Sources */, 3353 3369 ); 3354 3370 runOnlyForDeploymentPostprocessing = 0; -
trunk/Source/JavaScriptCore/dfg/DFGJITCodeGenerator.h
r95902 r96175 389 389 m_jit.loadDouble(JITCompiler::addressFor(spillMe), info.fpr()); 390 390 #elif USE(JSVALUE32_64) 391 UNUSED_PARAM(canTrample); 391 392 ASSERT(info.registerFormat() == DataFormatDouble || info.registerFormat() == DataFormatJSDouble); 392 393 m_jit.emitLoadDouble(nodeIndex, info.fpr()); … … 1284 1285 appendCallWithExceptionCheck(operation); 1285 1286 } 1286 void callOperation(D_DFGOperation_DD operation, FPRReg result, FPRReg arg1, FPRReg arg2) 1287 1288 void NO_RETURN callOperation(D_DFGOperation_DD operation, FPRReg result, FPRReg arg1, FPRReg arg2) 1287 1289 { 1288 1290 ASSERT(isFlushed()); … … 1290 1292 // FIXME: Need to to pass doubles. 1291 1293 ASSERT_NOT_REACHED(); 1294 UNUSED_PARAM(arg1); 1295 UNUSED_PARAM(arg2); 1292 1296 1293 1297 m_jit.appendCall(operation); -
trunk/Source/JavaScriptCore/dfg/DFGJITCodeGenerator32_64.cpp
r96171 r96175 220 220 { 221 221 // FIXME: For double we could fill with a FPR. 222 UNUSED_PARAM(fpr); 223 222 224 Node& node = m_jit.graph()[nodeIndex]; 223 225 VirtualRegister virtualRegister = node.virtualRegister(); … … 1894 1896 } 1895 1897 1896 void JITCodeGenerator::emitCall(Node& node)1898 void NO_RETURN JITCodeGenerator::emitCall(Node& node) 1897 1899 { 1898 1900 // FIXME: It's not supported yet! 1899 1901 ASSERT_NOT_REACHED(); 1902 UNUSED_PARAM(node); 1900 1903 } 1901 1904 -
trunk/Source/JavaScriptCore/dfg/DFGJITCompiler32_64.cpp
r96171 r96175 80 80 81 81 // This method used to fill a JSValue to a GPR when linking speculative -> non-speculative. 82 void JITCompiler::fillToJS(NodeIndex nodeIndex, GPRReg gpr)82 void NO_RETURN JITCompiler::fillToJS(NodeIndex nodeIndex, GPRReg gpr) 83 83 { 84 84 ASSERT_NOT_REACHED(); 85 UNUSED_PARAM(nodeIndex); 86 UNUSED_PARAM(gpr); 85 87 } 86 88 -
trunk/Source/JavaScriptCore/dfg/DFGNode.h
r95930 r96175 334 334 // a constant index, argument, or identifier) from a NodeIndex. 335 335 struct OpInfo { 336 explicit OpInfo(int value) : m_value(value) { } 337 #if USE(JSVALUE64) 338 explicit OpInfo(unsigned value) : m_value(value) { } 339 #endif 340 explicit OpInfo(uintptr_t value) : m_value(value) { } 336 explicit OpInfo(int32_t value) : m_value(static_cast<uintptr_t>(value)) { } 337 explicit OpInfo(uint32_t value) : m_value(static_cast<uintptr_t>(value)) { } 338 explicit OpInfo(size_t value) : m_value(static_cast<uintptr_t>(value)) { } 341 339 explicit OpInfo(void* value) : m_value(reinterpret_cast<uintptr_t>(value)) { } 342 340 uintptr_t m_value; -
trunk/Source/JavaScriptCore/dfg/DFGOperations.cpp
r95933 r96175 36 36 #include "Operations.h" 37 37 38 39 #if OS(DARWIN) || (OS(WINDOWS) && CPU(X86)) 40 #define SYMBOL_STRING(name) "_" #name 41 #else 42 #define SYMBOL_STRING(name) #name 43 #endif 44 38 45 #if CPU(X86_64) 39 46 #define FUNCTION_WRAPPER_WITH_RETURN_ADDRESS(function, register) \ 40 47 asm( \ 41 ".globl _" STRINGIZE(function) "\n" \42 "_" STRINGIZE(function) ":" "\n" \48 ".globl " SYMBOL_STRING(function) "\n" \ 49 SYMBOL_STRING(function) ":" "\n" \ 43 50 "mov (%rsp), %" STRINGIZE(register) "\n" \ 44 "jmp _" STRINGIZE(function) "WithReturnAddress" "\n" \51 "jmp " SYMBOL_STRING(function) "WithReturnAddress" "\n" \ 45 52 ); 46 53 #elif CPU(X86) 47 54 #define FUNCTION_WRAPPER_WITH_RETURN_ADDRESS(function, register) \ 48 55 asm( \ 49 ".globl " S TRINGIZE(function) "\n" \50 S TRINGIZE(function) ":" "\n" \56 ".globl " SYMBOL_STRING(function) "\n" \ 57 SYMBOL_STRING(function) ":" "\n" \ 51 58 "push (%esp)\n" \ 52 "jmp " S TRINGIZE(function) "WithReturnAddress" "\n" \59 "jmp " SYMBOL_STRING(function) "WithReturnAddress" "\n" \ 53 60 ); 54 61 #endif … … 266 273 EncodedJSValue operationGetMethodOptimizeWithReturnAddress(ExecState* exec, EncodedJSValue encodedBase, Identifier* propertyName, ReturnAddressPtr returnAddress) 267 274 #elif CPU(X86) 275 EncodedJSValue operationGetMethodOptimizeWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedBase, Identifier* propertyName); 268 276 FUNCTION_WRAPPER_WITH_ARG4_RETURN_ADDRESS(operationGetMethodOptimize); 269 277 EncodedJSValue operationGetMethodOptimizeWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedBase, Identifier* propertyName) … … 288 296 EncodedJSValue operationGetByIdBuildListWithReturnAddress(ExecState* exec, EncodedJSValue encodedBase, Identifier* propertyName, ReturnAddressPtr returnAddress) 289 297 #elif CPU(X86) 298 EncodedJSValue operationGetByIdBuildListWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedBase, Identifier* propertyName); 290 299 FUNCTION_WRAPPER_WITH_ARG4_RETURN_ADDRESS(operationGetByIdBuildList); 291 300 EncodedJSValue operationGetByIdBuildListWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedBase, Identifier* propertyName) … … 307 316 EncodedJSValue operationGetByIdProtoBuildListWithReturnAddress(ExecState* exec, EncodedJSValue encodedBase, Identifier* propertyName, ReturnAddressPtr returnAddress) 308 317 #elif CPU(X86) 318 EncodedJSValue operationGetByIdProtoBuildListWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedBase, Identifier* propertyName); 309 319 FUNCTION_WRAPPER_WITH_ARG4_RETURN_ADDRESS(operationGetByIdProtoBuildList); 310 320 EncodedJSValue operationGetByIdProtoBuildListWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedBase, Identifier* propertyName) … … 326 336 EncodedJSValue operationGetByIdOptimizeWithReturnAddress(ExecState* exec, EncodedJSValue encodedBase, Identifier* propertyName, ReturnAddressPtr returnAddress) 327 337 #elif CPU(X86) 338 EncodedJSValue operationGetByIdOptimizeWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedBase, Identifier* propertyName); 328 339 FUNCTION_WRAPPER_WITH_ARG4_RETURN_ADDRESS(operationGetByIdOptimize); 329 340 EncodedJSValue operationGetByIdOptimizeWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedBase, Identifier* propertyName) … … 389 400 void operationPutByIdStrictOptimizeWithReturnAddress(ExecState* exec, EncodedJSValue encodedValue, EncodedJSValue encodedBase, Identifier* propertyName, ReturnAddressPtr returnAddress) 390 401 #elif CPU(X86) 402 void operationPutByIdStrictOptimizeWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedValue, EncodedJSValue encodedBase, Identifier* propertyName); 391 403 FUNCTION_WRAPPER_WITH_ARG5_RETURN_ADDRESS(operationPutByIdStrictOptimize); 392 404 void operationPutByIdStrictOptimizeWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedValue, EncodedJSValue encodedBase, Identifier* propertyName) … … 411 423 void operationPutByIdNonStrictOptimizeWithReturnAddress(ExecState* exec, EncodedJSValue encodedValue, EncodedJSValue encodedBase, Identifier* propertyName, ReturnAddressPtr returnAddress) 412 424 #elif CPU(X86) 425 void operationPutByIdNonStrictOptimizeWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedValue, EncodedJSValue encodedBase, Identifier* propertyName); 413 426 FUNCTION_WRAPPER_WITH_ARG5_RETURN_ADDRESS(operationPutByIdNonStrictOptimize); 414 427 void operationPutByIdNonStrictOptimizeWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedValue, EncodedJSValue encodedBase, Identifier* propertyName) … … 433 446 void operationPutByIdDirectStrictOptimizeWithReturnAddress(ExecState* exec, EncodedJSValue encodedValue, EncodedJSValue encodedBase, Identifier* propertyName, ReturnAddressPtr returnAddress) 434 447 #elif CPU(X86) 448 void operationPutByIdDirectStrictOptimizeWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedValue, EncodedJSValue encodedBase, Identifier* propertyName); 435 449 FUNCTION_WRAPPER_WITH_ARG5_RETURN_ADDRESS(operationPutByIdDirectStrictOptimize); 436 450 void operationPutByIdDirectStrictOptimizeWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedValue, EncodedJSValue encodedBase, Identifier* propertyName) … … 455 469 void operationPutByIdDirectNonStrictOptimizeWithReturnAddress(ExecState* exec, EncodedJSValue encodedValue, EncodedJSValue encodedBase, Identifier* propertyName, ReturnAddressPtr returnAddress) 456 470 #elif CPU(X86) 471 void operationPutByIdDirectNonStrictOptimizeWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedValue, EncodedJSValue encodedBase, Identifier* propertyName); 457 472 FUNCTION_WRAPPER_WITH_ARG5_RETURN_ADDRESS(operationPutByIdDirectNonStrictOptimize); 458 473 void operationPutByIdDirectNonStrictOptimizeWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* exec, EncodedJSValue encodedValue, EncodedJSValue encodedBase, Identifier* propertyName) … … 518 533 #if CPU(X86_64) 519 534 asm ( 520 ".globl _" STRINGIZE(getHostCallReturnValue) "\n"521 "_" STRINGIZE(getHostCallReturnValue) ":" "\n"535 ".globl " SYMBOL_STRING(getHostCallReturnValue) "\n" 536 SYMBOL_STRING(getHostCallReturnValue) ":" "\n" 522 537 "mov -40(%r13), %r13\n" 523 538 "mov %r13, %rdi\n" 524 "jmp _" STRINGIZE(getHostCallReturnValueWithExecState) "\n"539 "jmp " SYMBOL_STRING(getHostCallReturnValueWithExecState) "\n" 525 540 ); 526 541 #elif CPU(X86) 527 542 asm ( 528 ".globl " S TRINGIZE(getHostCallReturnValue) "\n"529 S TRINGIZE(getHostCallReturnValue) ":" "\n"543 ".globl " SYMBOL_STRING(getHostCallReturnValue) "\n" 544 SYMBOL_STRING(getHostCallReturnValue) ":" "\n" 530 545 "mov -40(%edi), %edi\n" 531 546 "push %edi\n" 532 "jmp " S TRINGIZE(getHostCallReturnValueWithExecState) "\n"547 "jmp " SYMBOL_STRING(getHostCallReturnValueWithExecState) "\n" 533 548 ); 534 549 #endif … … 638 653 void* operationLinkCallWithReturnAddress(ExecState* execCallee, ReturnAddressPtr returnAddress) 639 654 #elif CPU(X86) 655 void* operationLinkCallWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* execCallee); 640 656 FUNCTION_WRAPPER_WITH_ARG2_RETURN_ADDRESS(operationLinkCall); 641 657 void* operationLinkCallWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* execCallee) … … 650 666 void* operationLinkConstructWithReturnAddress(ExecState* execCallee, ReturnAddressPtr returnAddress) 651 667 #elif CPU(X86) 668 void* operationLinkConstructWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* execCallee); 652 669 FUNCTION_WRAPPER_WITH_ARG2_RETURN_ADDRESS(operationLinkConstruct); 653 670 void* operationLinkConstructWithReturnAddress(ReturnAddressPtr returnAddress, ExecState* execCallee) -
trunk/Source/JavaScriptCore/dfg/DFGSpeculativeJIT.cpp
r95930 r96175 2097 2097 break; 2098 2098 } 2099 2099 2100 2100 case ForceOSRExit: { 2101 2101 terminateSpeculativeExecution(); -
trunk/Source/JavaScriptCore/dfg/DFGSpeculativeJIT32_64.cpp
r96171 r96175 127 127 fprintf(out, "-"); 128 128 break; 129 case AlreadyInRegisterFileAsUnboxedInt32: 130 fprintf(out, "(int32)"); 131 break; 129 132 case InGPR: 130 133 fprintf(out, "%%%s", GPRInfo::debugName(gpr())); … … 168 171 ASSERT(m_bytecodeIndex != std::numeric_limits<uint32_t>::max()); 169 172 for (unsigned argument = 0; argument < m_arguments.size(); ++argument) 170 m_arguments[argument] = jit->computeValueRecoveryFor( jit->m_arguments[argument]);173 m_arguments[argument] = jit->computeValueRecoveryFor(operandForArgument(argument), jit->m_arguments[argument]); 171 174 for (unsigned variable = 0; variable < m_variables.size(); ++variable) 172 m_variables[variable] = jit->computeValueRecoveryFor( jit->m_variables[variable]);175 m_variables[variable] = jit->computeValueRecoveryFor(variable, jit->m_variables[variable]); 173 176 } 174 177 … … 387 390 GPRReg SpeculativeJIT::fillSpeculateBoolean(NodeIndex nodeIndex) 388 391 { 392 ASSERT_NOT_REACHED(); 393 UNUSED_PARAM(nodeIndex); 394 389 395 #if ENABLE(DFG_DEBUG_VERBOSE) 390 396 fprintf(stderr, "SpecBool@%d ", nodeIndex); … … 2011 2017 } 2012 2018 2019 case ForceOSRExit: { 2020 terminateSpeculativeExecution(); 2021 break; 2022 } 2023 2013 2024 case Phantom: 2014 2025 // This is a no-op. … … 2133 2144 } 2134 2145 2135 // For any vars that we will be treating as numeric, write 0 to2136 // the var on entry. Throughout the block we will only read/write2137 // to the payload, by writing the tag now we prevent the GC from2138 // misinterpreting values as pointers.2139 void SpeculativeJIT::initializeVariableTypes()2140 {2141 ASSERT(!m_compileIndex);2142 for (int var = 0; var < (int)m_jit.graph().predictions().numberOfVariables(); ++var) {2143 if (isInt32Prediction(m_jit.graph().getPrediction(var)))2144 m_jit.store32(TrustedImm32(JSValue::Int32Tag), JITCompiler::tagFor((VirtualRegister)var));2145 }2146 }2147 2148 2146 bool SpeculativeJIT::compile() 2149 2147 { 2150 2148 checkArgumentTypes(); 2151 initializeVariableTypes();2152 2149 2153 2150 ASSERT(!m_compileIndex); … … 2158 2155 } 2159 2156 2160 ValueRecovery SpeculativeJIT::computeValueRecoveryFor( const ValueSource& valueSource)2157 ValueRecovery SpeculativeJIT::computeValueRecoveryFor(int operand, const ValueSource& valueSource) 2161 2158 { 2162 if (!valueSource.isSet()) 2159 if (!valueSource.isSet()) { 2160 if (m_bytecodeIndexForOSR && isInt32Prediction(m_jit.graph().getPrediction(operand))) 2161 return ValueRecovery::alreadyInRegisterFileAsUnboxedInt32(); 2163 2162 return ValueRecovery::alreadyInRegisterFile(); 2163 } 2164 2164 2165 2165 if (m_jit.isConstant(valueSource.nodeIndex()))
Note: See TracChangeset
for help on using the changeset viewer.