Changeset 59339 in webkit for trunk/JavaScriptCore/jit/JIT.cpp
- Timestamp:
- May 12, 2010, 9:01:56 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/jit/JIT.cpp
r59205 r59339 588 588 589 589 #if ENABLE(JIT_OPTIMIZE_CALL) 590 void JIT::unlinkCall (CallLinkInfo* callLinkInfo)590 void JIT::unlinkCallOrConstruct(CallLinkInfo* callLinkInfo) 591 591 { 592 592 // When the JSFunction is deleted the pointer embedded in the instruction stream will no longer be valid … … 620 620 repatchBuffer.relink(callLinkInfo->callReturnLocation, globalData->jitStubs.ctiVirtualCall()); 621 621 } 622 623 void JIT::linkConstruct(JSFunction* callee, CodeBlock* callerCodeBlock, CodeBlock* calleeCodeBlock, JITCode& code, CallLinkInfo* callLinkInfo, int callerArgCount, JSGlobalData* globalData) 624 { 625 RepatchBuffer repatchBuffer(callerCodeBlock); 626 627 // Currently we only link calls with the exact number of arguments. 628 // If this is a native call calleeCodeBlock is null so the number of parameters is unimportant 629 if (!calleeCodeBlock || (callerArgCount == calleeCodeBlock->m_numParameters)) { 630 ASSERT(!callLinkInfo->isLinked()); 631 632 if (calleeCodeBlock) 633 calleeCodeBlock->addCaller(callLinkInfo); 634 635 repatchBuffer.repatch(callLinkInfo->hotPathBegin, callee); 636 repatchBuffer.relink(callLinkInfo->hotPathOther, code.addressForCall()); 637 } 638 639 // patch the call so we do not continue to try to link. 640 repatchBuffer.relink(callLinkInfo->callReturnLocation, globalData->jitStubs.ctiVirtualConstruct()); 641 } 622 642 #endif // ENABLE(JIT_OPTIMIZE_CALL) 623 643
Note:
See TracChangeset
for help on using the changeset viewer.