Ignore:
Timestamp:
Feb 10, 2009, 12:43:32 AM (16 years ago)
Author:
[email protected]
Message:

2009-02-09 Gavin Barraclough <[email protected]>

Reviewed by Oliver Hunt.

Provide a class type for a generated block of JIT code.
Also changes the return address -> bytecode index map to
track the return addess as an unsigned offset into the code
instead of a ptrdiff_t in terms of voids - the latter is
equal to the actual offset / sizeof(void*), making it a
potentially lossy representation.

  • JavaScriptCore.xcodeproj/project.pbxproj:
  • assembler/AbstractMacroAssembler.h: (JSC::AbstractMacroAssembler::PatchBuffer::returnAddressOffset):
  • assembler/X86Assembler.h: (JSC::X86Assembler::getCallReturnOffset):
  • bytecode/CodeBlock.h: (JSC::CallReturnOffsetToBytecodeIndex::CallReturnOffsetToBytecodeIndex): (JSC::getCallReturnOffset): (JSC::CodeBlock::getBytecodeIndex): (JSC::CodeBlock::jitCode): (JSC::CodeBlock::callReturnIndexVector):
  • interpreter/Interpreter.cpp: (JSC::Interpreter::execute): (JSC::Interpreter::cti_vm_dontLazyLinkCall): (JSC::Interpreter::cti_vm_lazyLinkCall):
  • jit/JIT.cpp: (JSC::JIT::privateCompile):
  • jit/JIT.h: (JSC::):
  • jit/JITCall.cpp: (JSC::JIT::linkCall):
  • jit/JITCode.h: Added. (JSC::): (JSC::JITCode::JITCode): (JSC::JITCode::operator bool): (JSC::JITCode::addressForCall): (JSC::JITCode::offsetOf): (JSC::JITCode::execute):
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/jit/JITCall.cpp

    r40562 r40813  
    5353}
    5454
    55 void JIT::linkCall(JSFunction* callee, CodeBlock* calleeCodeBlock, void* ctiCode, CallLinkInfo* callLinkInfo, int callerArgCount)
     55void JIT::linkCall(JSFunction* callee, CodeBlock* calleeCodeBlock, JITCode ctiCode, CallLinkInfo* callLinkInfo, int callerArgCount)
    5656{
    5757    // Currently we only link calls with the exact number of arguments.
     
    6262   
    6363        DataLabelPtr::patch(callLinkInfo->hotPathBegin, callee);
    64         Jump::patch(callLinkInfo->hotPathOther, ctiCode);
     64        Jump::patch(callLinkInfo->hotPathOther, ctiCode.addressForCall());
    6565    }
    6666
Note: See TracChangeset for help on using the changeset viewer.