[llvm-commits] [vmkit] r52282 - /vmkit/trunk/lib/JnJVM/VMCore/JavaJIT.cpp
Nicolas Geoffray
nicolas.geoffray at lip6.fr
Sat Jun 14 11:21:02 PDT 2008
Author: geoffray
Date: Sat Jun 14 13:21:02 2008
New Revision: 52282
URL: http://llvm.org/viewvc/llvm-project?rev=52282&view=rev
Log:
On a synchronize method, an unwind destination is overridden if the existing
unwind destination is the try synchronize block.
Modified:
vmkit/trunk/lib/JnJVM/VMCore/JavaJIT.cpp
Modified: vmkit/trunk/lib/JnJVM/VMCore/JavaJIT.cpp
URL: http://llvm.org/viewvc/llvm-project/vmkit/trunk/lib/JnJVM/VMCore/JavaJIT.cpp?rev=52282&r1=52281&r2=52282&view=diff
==============================================================================
--- vmkit/trunk/lib/JnJVM/VMCore/JavaJIT.cpp (original)
+++ vmkit/trunk/lib/JnJVM/VMCore/JavaJIT.cpp Sat Jun 14 13:21:02 2008
@@ -855,6 +855,7 @@
}
BasicBlock* realEndExceptionBlock = endExceptionBlock;
+ BasicBlock* endExceptionBlockCatcher = endExceptionBlock;
currentExceptionBlock = endExceptionBlock;
if (sync) {
BasicBlock* synchronizeExceptionBlock =
@@ -862,6 +863,7 @@
BasicBlock* trySynchronizeExceptionBlock =
createBasicBlock("trySynchronizeExceptionBlock");
realEndExceptionBlock = synchronizeExceptionBlock;
+ endExceptionBlockCatcher = trySynchronizeExceptionBlock;
std::vector<Value*> argsSync;
if (isVirtual(compilingMethod->access)) {
argsSync.push_back(llvmFunction->arg_begin());
@@ -939,7 +941,7 @@
// We can do this because readExceptionTable is the first function to be
// called after creation of Opinfos
for (uint16 i = ex->startpc; i < ex->endpc; ++i) {
- if (opcodeInfos[i].exceptionBlock == realEndExceptionBlock) {
+ if (opcodeInfos[i].exceptionBlock == endExceptionBlockCatcher) {
opcodeInfos[i].exceptionBlock = ex->test;
}
}
More information about the llvm-commits
mailing list