harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mloe...@apache.org
Subject svn commit: r585123 - in /harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base: context_x.cpp stackmap.h tpool.cpp
Date Tue, 16 Oct 2007 11:40:21 GMT
Author: mloenko
Date: Tue Oct 16 04:40:17 2007
New Revision: 585123

URL: http://svn.apache.org/viewvc?rev=585123&view=rev
Log:
fix for HARMONY-4946 ([drlvm][verifier][regression] 19 VTSVM tests related to stack verification
failed after commit r584118)

Modified:
    harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/context_x.cpp
    harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/stackmap.h
    harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/tpool.cpp

Modified: harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/context_x.cpp
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/context_x.cpp?rev=585123&r1=585122&r2=585123&view=diff
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/context_x.cpp (original)
+++ harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/context_x.cpp Tue Oct 16
04:40:17 2007
@@ -731,7 +731,7 @@
             WorkmapElement value = workmap_pop();
 
             //check INs
-            if( !workmap_expect(value, SM_ONEWORDED) ) return error(VF_ErrorIncompatibleArgument,
"incompartible argument");
+            if( !workmap_expect(value, SM_LOW_WORD) ) return error(VF_ErrorIncompatibleArgument,
"incompartible argument");
 
             //push OUTs
             workmap_push( value );
@@ -750,7 +750,7 @@
             WorkmapElement value2 = workmap_pop();
 
             //check INs
-            if( !workmap_expect(value1, SM_ONEWORDED) || !workmap_expect(value2, SM_ONEWORDED)
) {
+            if( !workmap_expect(value1, SM_LOW_WORD) || !workmap_expect(value2, SM_LOW_WORD)
) {
                 return error(VF_ErrorIncompatibleArgument, "incompartible argument");
             }
 
@@ -772,8 +772,8 @@
             WorkmapElement value2 = workmap_pop();
             WorkmapElement value3 = workmap_pop();
 
-            //check INs  !!! SM_HIGH_WORD must be a one-word element !!!
-            if( !workmap_expect(value1, SM_ONEWORDED) || !workmap_expect(value2, SM_ONEWORDED)
) {
+            //check INs  !!! SM_HIGH_WORD is a two-word element: Long and Double are not
!!!
+            if( !workmap_expect(value1, SM_LOW_WORD) || !workmap_expect(value3, SM_LOW_WORD)
) {
                 return error(VF_ErrorIncompatibleArgument, "incompartible argument");
             }
 
@@ -797,7 +797,7 @@
             WorkmapElement value2 = workmap_pop();
 
             //check INs
-            if( !workmap_expect(value1, SM_ONEWORDED) ) {
+            if( !workmap_expect(value2, SM_LOW_WORD) ) {
                 return error(VF_ErrorIncompatibleArgument, "incompartible argument");
             }
 
@@ -822,7 +822,7 @@
             WorkmapElement value3 = workmap_pop();
 
             //check INs
-            if( !workmap_expect(value1, SM_ONEWORDED) || !workmap_expect(value3, SM_ONEWORDED)
) {
+            if( !workmap_expect(value2, SM_LOW_WORD) || !workmap_expect(value3, SM_LOW_WORD)
) {
                 return error(VF_ErrorIncompatibleArgument, "incompartible argument");
             }
 
@@ -849,7 +849,7 @@
             WorkmapElement value4 = workmap_pop();
 
             //check INs
-            if( !workmap_expect(value1, SM_ONEWORDED) || !workmap_expect(value3, SM_ONEWORDED)
) {
+            if( !workmap_expect(value2, SM_LOW_WORD) || !workmap_expect(value4, SM_LOW_WORD)
) {
                 return error(VF_ErrorIncompatibleArgument, "incompartible argument");
             }
 
@@ -1452,7 +1452,7 @@
             WorkmapElement value = workmap_pop();
 
             //check INs
-            if( !workmap_expect(value, SM_ONEWORDED) ) {
+            if( !workmap_expect(value, SM_LOW_WORD) ) {
                 return error(VF_ErrorIncompatibleArgument, "incompartible argument");
             }
             break;
@@ -1463,11 +1463,11 @@
             if( !workmap_can_pop(2) ) return error(VF_ErrorDataFlow, "unable to pop from
empty operand stack");
 
             //pop INs
-            WorkmapElement hi_val = workmap_pop();
             workmap_pop();
+            WorkmapElement lo_val = workmap_pop();
 
             //check INs
-            if( !workmap_expect(hi_val, SM_ONEWORDED) ) {
+            if( !workmap_expect(lo_val, SM_LOW_WORD) ) {
                 return error(VF_ErrorIncompatibleArgument, "incompartible argument");
             }
             break;
@@ -1515,8 +1515,8 @@
             WorkmapElement value2 = workmap_pop();
 
             //check INs
-            if( !workmap_expect(value1, SM_ONEWORDED) ||
-                !workmap_expect(value2, SM_ONEWORDED) )
+            if( !workmap_expect(value1, SM_LOW_WORD) ||
+                !workmap_expect(value2, SM_LOW_WORD) )
             {
                 return error(VF_ErrorIncompatibleArgument, "incompartible argument");
             }

Modified: harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/stackmap.h
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/stackmap.h?rev=585123&r1=585122&r2=585123&view=diff
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/stackmap.h (original)
+++ harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/stackmap.h Tue Oct 16 04:40:17
2007
@@ -37,7 +37,7 @@
     //predefined verification types
     enum SmConstPredefined {
         SM_NONE                         = 0,
-        SM_ONEWORDED                    = 1,
+        SM_LOW_WORD                     = 1,
         SM_REF_OR_UNINIT_OR_RETADR      = 3,
         SM_REF_OR_UNINIT                = 5,
         SM_THISUNINIT                   = 7,

Modified: harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/tpool.cpp
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/tpool.cpp?rev=585123&r1=585122&r2=585123&view=diff
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/tpool.cpp (original)
+++ harmony/enhanced/drlvm/trunk/vm/vmcore/src/verifier-3363/base/tpool.cpp Tue Oct 16 04:40:17
2007
@@ -145,15 +145,15 @@
 
         //migth have to change switch below if merging is done with constants
         assert( from != SM_NONE );
-        assert( from != SM_ONEWORDED );
+        assert( from != SM_LOW_WORD );
         assert( from != SM_REF_OR_UNINIT_OR_RETADR );
         assert( from != SM_REF_OR_UNINIT );
         assert( from != SM_ANYARRAY );
         assert( from != SM_BOGUS );
 
         switch ( to.c ) {
-        case SM_ONEWORDED:
-            return !from.isLongOrDouble();
+        case SM_LOW_WORD:
+            return from != SM_HIGH_WORD;
 
         case SM_REF_OR_UNINIT_OR_RETADR:
             return from == SM_NULL || from == SM_THISUNINIT || !from.isPrimitive();



Mime
View raw message