diff options
author | Simon Hausmann <simon.hausmann@nokia.com> | 2012-08-21 10:57:44 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@nokia.com> | 2012-08-21 10:57:44 +0200 |
commit | 5ef7c8a6a70875d4430752d146bdcb069605d71d (patch) | |
tree | f6256640b6c46d7da221435803cae65326817ba2 /Source/JavaScriptCore/llint/LLIntExceptions.cpp | |
parent | decad929f578d8db641febc8740649ca6c574638 (diff) | |
download | qtwebkit-5ef7c8a6a70875d4430752d146bdcb069605d71d.tar.gz |
Imported WebKit commit 356d83016b090995d08ad568f2d2c243aa55e831 (http://svn.webkit.org/repository/webkit/trunk@126147)
New snapshot including various build fixes for newer Qt 5
Diffstat (limited to 'Source/JavaScriptCore/llint/LLIntExceptions.cpp')
-rw-r--r-- | Source/JavaScriptCore/llint/LLIntExceptions.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/Source/JavaScriptCore/llint/LLIntExceptions.cpp b/Source/JavaScriptCore/llint/LLIntExceptions.cpp index 20b0db3d9..a915c42e3 100644 --- a/Source/JavaScriptCore/llint/LLIntExceptions.cpp +++ b/Source/JavaScriptCore/llint/LLIntExceptions.cpp @@ -37,6 +37,14 @@ namespace JSC { namespace LLInt { +static void fixupPCforExceptionIfNeeded(ExecState* exec) +{ + CodeBlock* codeBlock = exec->codeBlock(); + ASSERT(!!codeBlock); + Instruction* pc = exec->currentVPC(); + exec->setCurrentVPC(codeBlock->adjustPCIfAtCallSite(pc)); +} + void interpreterThrowInCaller(ExecState* exec, ReturnAddressPtr pc) { JSGlobalData* globalData = &exec->globalData(); @@ -44,6 +52,7 @@ void interpreterThrowInCaller(ExecState* exec, ReturnAddressPtr pc) #if LLINT_SLOW_PATH_TRACING dataLog("Throwing exception %s.\n", globalData->exception.description()); #endif + fixupPCforExceptionIfNeeded(exec); genericThrow( globalData, exec, globalData->exception, exec->codeBlock()->bytecodeOffset(exec, pc)); @@ -61,6 +70,7 @@ Instruction* returnToThrow(ExecState* exec, Instruction* pc) #if LLINT_SLOW_PATH_TRACING dataLog("Throwing exception %s (returnToThrow).\n", globalData->exception.description()); #endif + fixupPCforExceptionIfNeeded(exec); genericThrow(globalData, exec, globalData->exception, pc - exec->codeBlock()->instructions().begin()); return globalData->llintData.exceptionInstructions(); @@ -73,6 +83,7 @@ void* callToThrow(ExecState* exec, Instruction* pc) #if LLINT_SLOW_PATH_TRACING dataLog("Throwing exception %s (callToThrow).\n", globalData->exception.description()); #endif + fixupPCforExceptionIfNeeded(exec); genericThrow(globalData, exec, globalData->exception, pc - exec->codeBlock()->instructions().begin()); return bitwise_cast<void*>(&llint_throw_during_call_trampoline); |