Changeset 37316 in webkit for trunk/JavaScriptCore/VM/CTI.h


Ignore:
Timestamp:
Oct 5, 2008, 10:38:32 AM (17 years ago)
Author:
[email protected]
Message:

2008-10-05 Gavin Barraclough <[email protected]>

Reviewed by Cameron Zwarich.

Fix for bug #21387 - using SamplingTool with CTI.

(1) A repatch offset offset changes due to an additional instruction to update SamplingTool state.
(2) Fix an incusion order problem due to ExecState changes.
(3) Change to a MACHINE_SAMPLING macro, use of exec should now be accessing global data.

  • VM/CTI.h: (JSC::CTI::execute):
  • VM/SamplingTool.h: (JSC::SamplingTool::privateExecuteReturned):
  • kjs/Shell.cpp:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/VM/CTI.h

    r37297 r37316  
    3737#include <wtf/AlwaysInline.h>
    3838#include <wtf/Vector.h>
    39 
    40 #if ENABLE(SAMPLING_TOOL)
    41 #include "SamplingTool.h"
    42 #endif
    4339
    4440#if COMPILER(MSVC)
     
    260256        static const int repatchOffsetGetByIdBranchToSlowCase = 25;
    261257        static const int repatchOffsetGetByIdPropertyMapOffset = 34;
     258#if ENABLE(SAMPLING_TOOL)
     259        static const int repatchOffsetGetByIdSlowCaseCall = 27 + ctiArgumentInitSize;
     260#else
    262261        static const int repatchOffsetGetByIdSlowCaseCall = 17 + ctiArgumentInitSize;
     262#endif
    263263
    264264    public:
     
    326326        inline static JSValue* execute(void* code, RegisterFile* registerFile, Register* r, JSGlobalData* globalData, JSValue** exception)
    327327        {
    328             JSValue* value = ctiTrampoline(code, registerFile, r, exception, Profiler::enabledProfilerReference(), globalData);
    329 #if ENABLE(SAMPLING_TOOL)
    330             currentOpcodeID = static_cast<OpcodeID>(-1);
    331 #endif
    332             return value;
     328            return ctiTrampoline(code, registerFile, r, exception, Profiler::enabledProfilerReference(), globalData);
    333329        }
    334330
Note: See TracChangeset for help on using the changeset viewer.