diff options
author | Allan Sandfeld Jensen <allan.jensen@digia.com> | 2013-09-13 12:51:20 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-09-19 20:50:05 +0200 |
commit | d441d6f39bb846989d95bcf5caf387b42414718d (patch) | |
tree | e367e64a75991c554930278175d403c072de6bb8 /Source/JavaScriptCore/llint/LLIntExceptions.cpp | |
parent | 0060b2994c07842f4c59de64b5e3e430525c4b90 (diff) | |
download | qtwebkit-d441d6f39bb846989d95bcf5caf387b42414718d.tar.gz |
Import Qt5x2 branch of QtWebkit for Qt 5.2
Importing a new snapshot of webkit.
Change-Id: I2d01ad12cdc8af8cb015387641120a9d7ea5f10c
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@digia.com>
Diffstat (limited to 'Source/JavaScriptCore/llint/LLIntExceptions.cpp')
-rw-r--r-- | Source/JavaScriptCore/llint/LLIntExceptions.cpp | 35 |
1 files changed, 19 insertions, 16 deletions
diff --git a/Source/JavaScriptCore/llint/LLIntExceptions.cpp b/Source/JavaScriptCore/llint/LLIntExceptions.cpp index 17c15aa51..d88c16e7e 100644 --- a/Source/JavaScriptCore/llint/LLIntExceptions.cpp +++ b/Source/JavaScriptCore/llint/LLIntExceptions.cpp @@ -34,6 +34,7 @@ #include "JITExceptions.h" #include "LLIntCommon.h" #include "LowLevelInterpreter.h" +#include "Operations.h" namespace JSC { namespace LLInt { @@ -47,14 +48,14 @@ static void fixupPCforExceptionIfNeeded(ExecState* exec) void interpreterThrowInCaller(ExecState* exec, ReturnAddressPtr pc) { - JSGlobalData* globalData = &exec->globalData(); - NativeCallFrameTracer tracer(globalData, exec); + VM* vm = &exec->vm(); + NativeCallFrameTracer tracer(vm, exec); #if LLINT_SLOW_PATH_TRACING - dataLog("Throwing exception ", globalData->exception, ".\n"); + dataLog("Throwing exception ", vm->exception, ".\n"); #endif fixupPCforExceptionIfNeeded(exec); genericThrow( - globalData, exec, globalData->exception, + vm, exec, vm->exception, exec->codeBlock()->bytecodeOffset(exec, pc)); } @@ -64,29 +65,31 @@ Instruction* returnToThrowForThrownException(ExecState* exec) return LLInt::exceptionInstructions(); } +static void doThrow(ExecState* exec, Instruction* pc) +{ + VM* vm = &exec->vm(); + NativeCallFrameTracer tracer(vm, exec); + fixupPCforExceptionIfNeeded(exec); + genericThrow(vm, exec, vm->exception, pc - exec->codeBlock()->instructions().begin()); +} + Instruction* returnToThrow(ExecState* exec, Instruction* pc) { - JSGlobalData* globalData = &exec->globalData(); - NativeCallFrameTracer tracer(globalData, exec); #if LLINT_SLOW_PATH_TRACING - dataLog("Throwing exception ", globalData->exception, " (returnToThrow).\n"); + VM* vm = &exec->vm(); + dataLog("Throwing exception ", vm->exception, " (returnToThrow).\n"); #endif - fixupPCforExceptionIfNeeded(exec); - genericThrow(globalData, exec, globalData->exception, pc - exec->codeBlock()->instructions().begin()); - + doThrow(exec, pc); return LLInt::exceptionInstructions(); } void* callToThrow(ExecState* exec, Instruction* pc) { - JSGlobalData* globalData = &exec->globalData(); - NativeCallFrameTracer tracer(globalData, exec); #if LLINT_SLOW_PATH_TRACING - dataLog("Throwing exception ", globalData->exception, " (callToThrow).\n"); + VM* vm = &exec->vm(); + dataLog("Throwing exception ", vm->exception, " (callToThrow).\n"); #endif - fixupPCforExceptionIfNeeded(exec); - genericThrow(globalData, exec, globalData->exception, pc - exec->codeBlock()->instructions().begin()); - + doThrow(exec, pc); return LLInt::getCodePtr(llint_throw_during_call_trampoline); } |