diff options
Diffstat (limited to 'Source/JavaScriptCore/bytecode/SamplingTool.h')
-rw-r--r-- | Source/JavaScriptCore/bytecode/SamplingTool.h | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/Source/JavaScriptCore/bytecode/SamplingTool.h b/Source/JavaScriptCore/bytecode/SamplingTool.h index 9ca54da..a0696b1 100644 --- a/Source/JavaScriptCore/bytecode/SamplingTool.h +++ b/Source/JavaScriptCore/bytecode/SamplingTool.h @@ -95,8 +95,8 @@ namespace JSC { struct Instruction; struct ScriptSampleRecord { - ScriptSampleRecord(ScriptExecutable* executable) - : m_executable(executable) + ScriptSampleRecord(JSGlobalData& globalData, ScriptExecutable* executable) + : m_executable(globalData, executable) , m_codeBlock(0) , m_sampleCount(0) , m_opcodeSampleCount(0) @@ -113,7 +113,7 @@ namespace JSC { void sample(CodeBlock*, Instruction*); - RefPtr<ScriptExecutable> m_executable; + Global<ScriptExecutable> m_executable; CodeBlock* m_codeBlock; int m_sampleCount; int m_opcodeSampleCount; @@ -280,7 +280,6 @@ namespace JSC { // Implements a named set of counters, printed on exit if ENABLE(SAMPLING_COUNTERS). // See subclasses below, SamplingCounter, GlobalSamplingCounter and DeletableSamplingCounter. class AbstractSamplingCounter { - friend class JIT; friend class DeletableSamplingCounter; public: void count(uint32_t count = 1) @@ -290,6 +289,8 @@ namespace JSC { static void dump(); + int64_t* addressOfCounter() { return &m_counter; } + protected: // Effectively the contructor, however called lazily in the case of GlobalSamplingCounter. void init(const char* name) |