Ignore:
Timestamp:
Jun 4, 2012, 5:00:17 PM (13 years ago)
Author:
[email protected]
Message:

Remove enabledProfilerReference
https://bugs.webkit.org/show_bug.cgi?id=88258

Reviewed by Michael Saboff.

Make the enabled profiler a member of JSGlobalData, and switch code that accesses it to do so directly
via the JSGlobalData, rather than holding a Profiler reference to it. Do not pass the Profiler
reference to JIT code. This patch does not change the stack layout on entry into JIT code (passing an
unused void* instead), since this is an intrusive change better handled in a separate patch.

  • interpreter/Interpreter.cpp:

(JSC::Interpreter::throwException):
(JSC::Interpreter::execute):
(JSC::Interpreter::executeCall):
(JSC::Interpreter::executeConstruct):
(JSC::Interpreter::privateExecute):

  • jit/JITCode.h:

(JSC::JITCode::execute):

  • Don't pass Profiler to JIT code.
  • jit/JITOpcodes.cpp:

(JSC::JIT::emit_op_profile_will_call):
(JSC::JIT::emit_op_profile_did_call):

  • jit/JITOpcodes32_64.cpp:

(JSC::JIT::emit_op_profile_will_call):
(JSC::JIT::emit_op_profile_did_call):

  • jit/JITStubs.cpp:

(JSC):
(JSC::ctiTrampoline):
(JSC::ctiVMThrowTrampoline):
(JSC::ctiOpThrowNotCaught):
(JSC::JITThunks::JITThunks):
(JSC::DEFINE_STUB_FUNCTION):

  • For ARM_THUMB2, rename ENABLE_PROFILER_REFERENCE_OFFSET to FIRST_STACK_ARGUMENT (which is how it is being used).
  • For MIPS, remove ENABLE_PROFILER_REFERENCE_OFFSET.
  • jit/JITStubs.h:

(JITStackFrame):
(JSC):

  • Renamed enabledProfilerReference to unusedX.
  • llint/LLIntSlowPaths.cpp:

(JSC::LLInt::LLINT_SLOW_PATH_DECL):

  • llint/LowLevelInterpreter.asm:
  • profiler/Profiler.cpp:

(JSC):
(JSC::Profiler::startProfiling):
(JSC::Profiler::stopProfiling):

  • profiler/Profiler.h:

(Profiler):

  • Removed s_sharedEnabledProfilerReference, enabledProfilerReference().
  • runtime/JSGlobalData.cpp:

(JSC::JSGlobalData::JSGlobalData):

  • runtime/JSGlobalData.h:

(JSC):
(JSC::JSGlobalData::enabledProfiler):
(JSGlobalData):

  • Added m_enabledProfiler, enabledProfiler().
  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::~JSGlobalObject):

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/jit/JITStubs.h

    r118344 r119441  
    105105        CallFrame* callFrame;
    106106        void* unused1;
    107         Profiler** enabledProfilerReference;
     107        void* unused2;
    108108        JSGlobalData* globalData;
    109109
     
    141141        CallFrame* callFrame;
    142142        void* unused1;
    143         Profiler** enabledProfilerReference;
     143        void* unused2;
    144144        JSGlobalData* globalData;
    145145       
     
    172172
    173173        // These arguments passed on the stack.
    174         Profiler** enabledProfilerReference;
     174        void* unused1;
    175175        JSGlobalData* globalData;
    176176       
     
    200200
    201201        // These arguments passed on the stack.
    202         Profiler** enabledProfilerReference;
     202        void* unused2;
    203203        JSGlobalData* globalData;
    204204
     
    232232
    233233        // These arguments passed on the stack.
    234         Profiler** enabledProfilerReference;
     234        void* unused2;
    235235        JSGlobalData* globalData;
    236236
     
    253253        CallFrame* callFrame;
    254254        JSValue* exception;
    255         Profiler** enabledProfilerReference;
     255        void* unused1;
    256256        JSGlobalData* globalData;
    257257
     
    283283    extern "C" void ctiVMThrowTrampoline();
    284284    extern "C" void ctiOpThrowNotCaught();
    285     extern "C" EncodedJSValue ctiTrampoline(void* code, RegisterFile*, CallFrame*, void* /*unused1*/, Profiler**, JSGlobalData*);
     285    extern "C" EncodedJSValue ctiTrampoline(void* code, RegisterFile*, CallFrame*, void* /*unused1*/, void* /*unused2*/, JSGlobalData*);
    286286#if ENABLE(DFG_JIT)
    287287    extern "C" void ctiTrampolineEnd();
Note: See TracChangeset for help on using the changeset viewer.