harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From var...@apache.org
Subject svn commit: r474239 - /incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/ControlFlowGraph.cpp
Date Mon, 13 Nov 2006 10:40:08 GMT
Author: varlax
Date: Mon Nov 13 02:40:07 2006
New Revision: 474239

URL: http://svn.apache.org/viewvc?view=rev&rev=474239
Log:
HARMONY-1909 [drlvm][opt] failed assert in Node::insertInst
Tested on SUSE9, c-unit, smoke, kernel

Modified:
    incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/ControlFlowGraph.cpp

Modified: incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/ControlFlowGraph.cpp
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/ControlFlowGraph.cpp?view=diff&rev=474239&r1=474238&r2=474239
==============================================================================
--- incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/ControlFlowGraph.cpp (original)
+++ incubator/harmony/enhanced/drlvm/trunk/vm/jitrino/src/shared/ControlFlowGraph.cpp Mon
Nov 13 02:40:07 2006
@@ -500,6 +500,16 @@
     Node* sourceDispatch = source->getExceptionEdgeTarget();
     Node* targetDispatch = target->getExceptionEdgeTarget();
 
+    //check if there is no problem with header critical insts
+    if (source->getLastInst()!=NULL && !source->getLastInst()->isHeaderCriticalInst())
{
+        //we can't allow target to have critical insts except label
+        CFGInst* inst = target->getFirstInst();
+        inst = inst!=NULL?(inst->isLabel() ? inst->next() : inst) : NULL;
+        if (inst!=NULL && inst->isHeaderCriticalInst()) {
+            return false;
+        }
+    }
+
     if (source->getOutDegree() == 2 && sourceDispatch == 0) {
         return false; // 2 uncond edges, e.g. indirect jumps
     }



Mime
View raw message