diff options
author | Simon Hausmann <simon.hausmann@digia.com> | 2012-09-25 13:02:02 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@digia.com> | 2012-09-25 13:02:02 +0200 |
commit | 715be629d51174233403237bfc563cf150087dc8 (patch) | |
tree | 4cff72df808db977624338b0a38d8b6d1bd73c57 /Source/JavaScriptCore/runtime/JSGlobalData.cpp | |
parent | dc6262b587c71c14e30d93e57ed812e36a79a33e (diff) | |
download | qtwebkit-715be629d51174233403237bfc563cf150087dc8.tar.gz |
Imported WebKit commit ce614b0924ba46f78d4435e28ff93c8525fbb7cc (http://svn.webkit.org/repository/webkit/trunk@129485)
New snapshot that includes MingW build fixes
Diffstat (limited to 'Source/JavaScriptCore/runtime/JSGlobalData.cpp')
-rw-r--r-- | Source/JavaScriptCore/runtime/JSGlobalData.cpp | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/Source/JavaScriptCore/runtime/JSGlobalData.cpp b/Source/JavaScriptCore/runtime/JSGlobalData.cpp index 26f2b8616..e30a7913d 100644 --- a/Source/JavaScriptCore/runtime/JSGlobalData.cpp +++ b/Source/JavaScriptCore/runtime/JSGlobalData.cpp @@ -97,7 +97,11 @@ extern const HashTable regExpPrototypeTable; extern const HashTable stringTable; extern const HashTable stringConstructorTable; -#if ENABLE(ASSEMBLER) && (ENABLE(CLASSIC_INTERPRETER) || ENABLE(LLINT)) +// Note: Platform.h will enforce that ENABLE(ASSEMBLER) is true if either +// ENABLE(JIT) or ENABLE(YARR_JIT) or both are enabled. The code below +// just checks for ENABLE(JIT) or ENABLE(YARR_JIT) with this premise in mind. + +#if ENABLE(ASSEMBLER) static bool enableAssembler(ExecutableAllocator& executableAllocator) { if (!executableAllocator.isValid() || (!Options::useJIT() && !Options::useRegExpJIT())) @@ -124,7 +128,7 @@ static bool enableAssembler(ExecutableAllocator& executableAllocator) return true; #endif } -#endif +#endif // ENABLE(!ASSEMBLER) JSGlobalData::JSGlobalData(GlobalDataType globalDataType, ThreadStackType threadStackType, HeapType heapType) : @@ -180,9 +184,13 @@ JSGlobalData::JSGlobalData(GlobalDataType globalDataType, ThreadStackType thread , m_timeoutCount(512) #endif , m_newStringsSinceLastHashConst(0) -#if ENABLE(ASSEMBLER) && (ENABLE(CLASSIC_INTERPRETER) || ENABLE(LLINT)) +#if ENABLE(ASSEMBLER) , m_canUseAssembler(enableAssembler(executableAllocator)) +#endif +#if ENABLE(JIT) , m_canUseJIT(m_canUseAssembler && Options::useJIT()) +#endif +#if ENABLE(YARR_JIT) , m_canUseRegExpJIT(m_canUseAssembler && Options::useRegExpJIT()) #endif #if ENABLE(GC_VALIDATION) @@ -370,10 +378,6 @@ static ThunkGenerator thunkGeneratorForIntrinsic(Intrinsic intrinsic) NativeExecutable* JSGlobalData::getHostFunction(NativeFunction function, NativeFunction constructor) { -#if ENABLE(CLASSIC_INTERPRETER) - if (!canUseJIT()) - return NativeExecutable::create(*this, function, constructor); -#endif return jitStubs->hostFunctionStub(this, function, constructor); } NativeExecutable* JSGlobalData::getHostFunction(NativeFunction function, Intrinsic intrinsic) |