diff options
author | Simon Hausmann <simon.hausmann@digia.com> | 2012-11-30 16:58:06 +0100 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@digia.com> | 2012-11-30 17:03:09 +0100 |
commit | 32ea33253afbbdefd2680aa95ab5f57455272ae7 (patch) | |
tree | 2389569585b666c310fbb36d3fb8e6ab94462967 /Source/JavaScriptCore/bytecode/CodeBlock.h | |
parent | 41c25f231cbca1babc445187283524cc6c751c71 (diff) | |
download | qtwebkit-32ea33253afbbdefd2680aa95ab5f57455272ae7.tar.gz |
Imported WebKit commit 6a4a1d32e1d779548c726c4826cba9d69eb87601 (http://svn.webkit.org/repository/webkit/trunk@136242)
Final import for the Qt 5.x series that implements the QtWebKit / QtWebKitWidgets split
Extra fixes will be cherry-picked.
Change-Id: I844f1ebb99c6d6b75db31d6538c2acd628e79681
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'Source/JavaScriptCore/bytecode/CodeBlock.h')
-rw-r--r-- | Source/JavaScriptCore/bytecode/CodeBlock.h | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/Source/JavaScriptCore/bytecode/CodeBlock.h b/Source/JavaScriptCore/bytecode/CodeBlock.h index 63a03630e..20f1e7452 100644 --- a/Source/JavaScriptCore/bytecode/CodeBlock.h +++ b/Source/JavaScriptCore/bytecode/CodeBlock.h @@ -35,6 +35,7 @@ #include "BytecodeConventions.h" #include "CallLinkInfo.h" #include "CallReturnOffsetToBytecodeOffset.h" +#include "CodeBlockHash.h" #include "CodeOrigin.h" #include "CodeType.h" #include "Comment.h" @@ -128,6 +129,10 @@ namespace JSC { public: JS_EXPORT_PRIVATE virtual ~CodeBlock(); + CodeBlockHash hash() const; + void dumpAssumingJITType(PrintStream&, JITCode::JITType) const; + void dump(PrintStream&) const; + int numParameters() const { return m_numParameters; } void setNumParameters(int newValue); @@ -138,11 +143,9 @@ namespace JSC { PassOwnPtr<CodeBlock> releaseAlternative() { return m_alternative.release(); } void setAlternative(PassOwnPtr<CodeBlock> alternative) { m_alternative = alternative; } - CodeSpecializationKind specializationKind() + CodeSpecializationKind specializationKind() const { - if (m_isConstructor) - return CodeForConstruct; - return CodeForCall; + return specializationFromIsConstruct(m_isConstructor); } #if ENABLE(JIT) @@ -163,8 +166,8 @@ namespace JSC { static void dumpStatistics(); - void dump(); - void dump(unsigned bytecodeOffset); + void dumpBytecode(); + void dumpBytecode(unsigned bytecodeOffset); void printStructures(const Instruction*); void printStructure(const char* name, const Instruction*, int operand); @@ -472,7 +475,7 @@ namespace JSC { } JITCode& getJITCode() { return m_jitCode; } MacroAssemblerCodePtr getJITCodeWithArityCheck() { return m_jitCodeWithArityCheck; } - JITCode::JITType getJITType() { return m_jitCode.jitType(); } + JITCode::JITType getJITType() const { return m_jitCode.jitType(); } ExecutableMemoryHandle* executableMemory() { return getJITCode().getExecutableMemory(); } virtual JSObject* compileOptimized(ExecState*, JSScope*, unsigned bytecodeIndex) = 0; virtual void jettison() = 0; @@ -1212,7 +1215,7 @@ namespace JSC { m_constantRegisters[i].set(*m_globalData, ownerExecutable(), constants[i].get()); } - void dump(ExecState*, const Instruction* begin, const Instruction*&); + void dumpBytecode(ExecState*, const Instruction* begin, const Instruction*&); CString registerName(ExecState*, int r) const; void printUnaryOp(ExecState*, int location, const Instruction*&, const char* op); |