Ignore:
Timestamp:
Sep 30, 2020, 10:15:14 PM (5 years ago)
Author:
[email protected]
Message:

[JSC] We should not tag C function with JIT code related ptr tag
https://bugs.webkit.org/show_bug.cgi?id=217150

Reviewed by Mark Lam.

We are tagging getHostCallReturnValue function with JIT related PtrTag. As a part of JIT-caging effort, we are restricting our
PtrTag usage more for code types (e.g. JIT code should be tagged with JIT related PtrTag). So, we should not tag getHostCallReturnValue
with that. This patch implements getHostCallReturnValue in JIT code if JIT is enabled. If not, it is implemented by LLInt.

  • JavaScriptCore.xcodeproj/project.pbxproj:
  • Sources.txt:
  • bytecode/BytecodeList.rb:
  • dfg/DFGCapabilities.cpp:

(JSC::DFG::capabilityLevel):

  • heap/MarkedBlock.h:

(JSC::MarkedBlock::Footer::offsetOfVM):

  • heap/PreciseAllocation.h:

(JSC::PreciseAllocation::offsetOfWeakSet):

  • heap/WeakSet.h:

(JSC::WeakSet::offsetOfVM):

  • jit/HostCallReturnValue.cpp: Removed.
  • jit/HostCallReturnValue.h: Removed.
  • jit/JITOperations.cpp:
  • jit/JITOperationsMSVC64.cpp: Removed.
  • jit/JITStubsMSVC64.asm:
  • llint/LLIntEntrypoint.cpp:

(JSC::LLInt::getHostCallReturnValueEntrypoint):

  • llint/LLIntEntrypoint.h:
  • llint/LLIntSlowPaths.cpp:

(JSC::LLInt::handleHostCall):
(JSC::LLInt::commonCallEval):

  • llint/LLIntThunks.cpp:

(JSC::LLInt::getHostCallReturnValueThunk):

  • llint/LLIntThunks.h:
  • llint/LowLevelInterpreter.cpp:

(JSC::CLoop::execute):

  • llint/LowLevelInterpreter32_64.asm:
  • llint/LowLevelInterpreter64.asm:
  • runtime/JSCellInlines.h:

(JSC::tryAllocateCellHelper):

  • runtime/JSGlobalObject.h:

(JSC::JSGlobalObject::offsetOfVM):

  • runtime/VM.cpp:

(JSC::VM::VM):

  • runtime/VM.h:

(JSC::VM::offsetOfEncodedHostCallReturnValue):

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/runtime/VM.cpp

    r267132 r267820  
    6464#include "Heap.h"
    6565#include "HeapProfiler.h"
    66 #include "HostCallReturnValue.h"
    6766#include "Interpreter.h"
    6867#include "IntlCache.h"
     
    491490    Thread::current().setCurrentAtomStringTable(existingEntryAtomStringTable);
    492491   
    493 #if !ENABLE(C_LOOP)
    494     initializeHostCallReturnValue(); // This is needed to convince the linker not to drop host call return support.
    495 #endif
    496    
    497492    Gigacage::addPrimitiveDisableCallback(primitiveGigacageDisabledCallback, this);
    498493
Note: See TracChangeset for help on using the changeset viewer.