[kaffe] CVS kaffe (robilad): Cross-compilation fix for verifier

Kaffe CVS cvs-commits at kaffe.org
Sun Mar 13 08:10:06 PST 2005


PatchSet 5540 
Date: 2005/03/13 16:03:41
Author: robilad
Branch: HEAD
Tag: (none) 
Log:
Cross-compilation fix for verifier

2005-03-13  Dalibor Topic  <robilad at kaffe.org>

* kaffe/kaffevm/verifier/verify-type.c
(TBYTEARR): Made static.
(getTBYTEARR) Added.

* kaffe/kaffevm/verifier/verify-type.h:
(TBYTEARR) Removed prototype.
(getTBYTEARR) Added prototype.

* kaffe/kaffevm/verifier/verify-debug.c,
kaffe/kaffevm/verifier/verify-block.c:
Replaced use of TBYTEARR by getTBYTEARR.

Members: 
	ChangeLog:1.3714->1.3715 
	kaffe/kaffevm/verifier/verify-block.c:1.13->1.14 
	kaffe/kaffevm/verifier/verify-debug.c:1.8->1.9 
	kaffe/kaffevm/verifier/verify-type.c:1.16->1.17 
	kaffe/kaffevm/verifier/verify-type.h:1.13->1.14 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.3714 kaffe/ChangeLog:1.3715
--- kaffe/ChangeLog:1.3714	Sun Mar 13 15:58:45 2005
+++ kaffe/ChangeLog	Sun Mar 13 16:03:41 2005
@@ -1,6 +1,20 @@
 2005-03-13  Dalibor Topic  <robilad at kaffe.org>
 
 	* kaffe/kaffevm/verifier/verify-type.c
+	(TBYTEARR): Made static. 
+	(getTBYTEARR) Added.
+
+	* kaffe/kaffevm/verifier/verify-type.h: 
+	(TBYTEARR) Removed prototype.
+	(getTBYTEARR) Added prototype.
+
+	* kaffe/kaffevm/verifier/verify-debug.c,
+	kaffe/kaffevm/verifier/verify-block.c:
+	Replaced use of TBYTEARR by getTBYTEARR.
+	
+2005-03-13  Dalibor Topic  <robilad at kaffe.org>
+
+	* kaffe/kaffevm/verifier/verify-type.c
 	(TBOOLARR): Made static. 
 	(getTBOOLARR) Added.
 
Index: kaffe/kaffe/kaffevm/verifier/verify-block.c
diff -u kaffe/kaffe/kaffevm/verifier/verify-block.c:1.13 kaffe/kaffe/kaffevm/verifier/verify-block.c:1.14
--- kaffe/kaffe/kaffevm/verifier/verify-block.c:1.13	Sun Mar 13 15:58:50 2005
+++ kaffe/kaffe/kaffevm/verifier/verify-block.c	Sun Mar 13 16:03:44 2005
@@ -724,7 +724,7 @@
 			case TYPE_Char:    OPSTACK_PUSH(TCHARARR);   break;
 			case TYPE_Float:   OPSTACK_PUSH(getTFLOATARR());  break;
 			case TYPE_Double:  OPSTACK_PUSH(getTDOUBLEARR()); break;
-			case TYPE_Byte:    OPSTACK_PUSH(TBYTEARR);   break;
+			case TYPE_Byte:    OPSTACK_PUSH(getTBYTEARR());   break;
 			case TYPE_Short:   OPSTACK_PUSH(getTSHORTARR());  break;
 			case TYPE_Int:     OPSTACK_PUSH(getTINTARR());    break;
 			case TYPE_Long:    OPSTACK_PUSH(getTLONGARR());   break;
@@ -795,7 +795,7 @@
 			/* BALOAD can be used for bytes or booleans .... */
 			OPSTACK_POP_T(TINT);
 
-			if (!typecheck (v, TBYTEARR, getOpstackTop(block)) &&
+			if (!typecheck (v, getTBYTEARR(), getOpstackTop(block)) &&
 			    !typecheck (v, getTBOOLARR(), getOpstackTop(block))) {
                                 DBG(VERIFY3,
                                     dprintf("                OPSTACK_TOP: ");
@@ -881,7 +881,7 @@
 			OPSTACK_POP_T(TINT);
 			OPSTACK_POP_T(TINT);
 
-			if ( !typecheck(v, TBYTEARR, getOpstackTop(block)) &&
+			if ( !typecheck(v, getTBYTEARR(), getOpstackTop(block)) &&
 			     !typecheck(v, getTBOOLARR(), getOpstackTop(block))) {
 				DBG(VERIFY3,
 				    dprintf("                OPSTACK_TOP: ");
Index: kaffe/kaffe/kaffevm/verifier/verify-debug.c
diff -u kaffe/kaffe/kaffevm/verifier/verify-debug.c:1.8 kaffe/kaffe/kaffevm/verifier/verify-debug.c:1.9
--- kaffe/kaffe/kaffevm/verifier/verify-debug.c:1.8	Sun Mar 13 15:58:50 2005
+++ kaffe/kaffe/kaffevm/verifier/verify-debug.c	Sun Mar 13 16:03:44 2005
@@ -462,7 +462,7 @@
 		else if (type == getTBOOLARR()->data.class) {
 			dprintf("TBOOLARR");
 		}
-		else if (type == TBYTEARR->data.class) {
+		else if (type == getTBYTEARR()->data.class) {
 			dprintf("TBYTEARR");
 		}
 		else if (type == getTSHORTARR()->data.class) {
Index: kaffe/kaffe/kaffevm/verifier/verify-type.c
diff -u kaffe/kaffe/kaffevm/verifier/verify-type.c:1.16 kaffe/kaffe/kaffevm/verifier/verify-type.c:1.17
--- kaffe/kaffe/kaffevm/verifier/verify-type.c:1.16	Sun Mar 13 15:58:50 2005
+++ kaffe/kaffe/kaffevm/verifier/verify-type.c	Sun Mar 13 16:03:44 2005
@@ -90,7 +90,12 @@
 
 static const char* BYTEARR_SIG = "[B";
 static Type  verify_BYTEARR;
-Type* TBYTEARR = &verify_BYTEARR;
+static Type* TBYTEARR = &verify_BYTEARR;
+
+Type* getTBYTEARR(void)
+{
+  return TBYTEARR;
+}
 
 static const char* BOOLARR_SIG = "[Z";
 static Type  verify_BOOLARR;
Index: kaffe/kaffe/kaffevm/verifier/verify-type.h
diff -u kaffe/kaffe/kaffevm/verifier/verify-type.h:1.13 kaffe/kaffe/kaffevm/verifier/verify-type.h:1.14
--- kaffe/kaffe/kaffevm/verifier/verify-type.h:1.13	Sun Mar 13 15:58:50 2005
+++ kaffe/kaffe/kaffevm/verifier/verify-type.h	Sun Mar 13 16:03:44 2005
@@ -106,7 +106,7 @@
 
 extern Type* TOBJARR;
 extern Type* TCHARARR;
-extern Type* TBYTEARR;
+extern Type* getTBYTEARR(void);
 extern Type* getTBOOLARR(void);
 extern Type* getTSHORTARR(void);
 extern Type* getTINTARR(void);




More information about the kaffe mailing list