[kaffe] CVS kaffe (dalibor): Moved block handling out of verifier

Kaffe CVS cvs-commits at kaffe.org
Tue Mar 2 09:57:03 PST 2004


PatchSet 4477 
Date: 2004/03/02 17:48:44
Author: dalibor
Branch: HEAD
Tag: (none) 
Log:
Moved block handling out of verifier

2004-03-02  Dalibor Topic <robilad at kaffe.org>

        * kaffe/kaffevm/verify-block.c,
        kaffe/kaffevm/verify-block.h:
        New files.

        * kaffe/kaffevm/Makefile.am:
        (libkaffevm_la_SOURCES): Added verify-block.c.
        (noinst_HEADERS): Added verify-block.h.

        * kaffe/kaffevm/Makefile.in:
        Regenerated.

        * kaffe/kaffevm/verify-debug.c:
        Include verify-uninit.h.

        * kaffe/kaffevm/verify-debug.h,
        kaffe/kaffevm/verify-sigstack.h,
        kaffe/kaffevm/verify-uninit.h:
        Added preprocessor guards. Fix up includes.

        * kaffe/kaffevm/verify.c,
        kaffe/kaffevm/verify.h:
        (UninitializedType) Moved over to
        kaffe/kaffevm/verify-uninit.h.
        (BlockInfo, CHANGED, VISITED, IS_INSTRUCTION,
        WIDE_MODDED, START_BLOCK, END_BLOCK, EXCEPTION_HANDLER)
        Moved over to kaffe/kaffevm/verify-block.h.
        (createBlock, copyBlockData, copyBlockState, freeBlock,
        inWhichBlock) Moved over to
        kaffe/kaffevm/verify-block.c.

Members: 
	ChangeLog:1.2057->1.2058 
	kaffe/kaffevm/Makefile.am:1.52->1.53 
	kaffe/kaffevm/Makefile.in:1.135->1.136 
	kaffe/kaffevm/verify-block.c:INITIAL->1.1 
	kaffe/kaffevm/verify-block.h:INITIAL->1.1 
	kaffe/kaffevm/verify-debug.c:1.1->1.2 
	kaffe/kaffevm/verify-debug.h:1.1->1.2 
	kaffe/kaffevm/verify-sigstack.h:1.1->1.2 
	kaffe/kaffevm/verify-uninit.h:1.1->1.2 
	kaffe/kaffevm/verify.c:1.69->1.70 
	kaffe/kaffevm/verify.h:1.9->1.10 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.2057 kaffe/ChangeLog:1.2058
--- kaffe/ChangeLog:1.2057	Sun Feb 29 20:14:26 2004
+++ kaffe/ChangeLog	Tue Mar  2 17:48:44 2004
@@ -1,3 +1,35 @@
+2004-03-02  Dalibor Topic <robilad at kaffe.org>
+
+        * kaffe/kaffevm/verify-block.c,
+        kaffe/kaffevm/verify-block.h:
+	New files.
+
+        * kaffe/kaffevm/Makefile.am:
+	(libkaffevm_la_SOURCES): Added verify-block.c.
+        (noinst_HEADERS): Added verify-block.h.
+
+        * kaffe/kaffevm/Makefile.in:
+	Regenerated.
+
+        * kaffe/kaffevm/verify-debug.c:
+	Include "verify-uninit.h".
+
+        * kaffe/kaffevm/verify-debug.h,
+        kaffe/kaffevm/verify-sigstack.h,
+        kaffe/kaffevm/verify-uninit.h:
+	Added preprocessor guards. Fix up includes.
+
+        * kaffe/kaffevm/verify.c,
+        kaffe/kaffevm/verify.h:
+	(UninitializedType) Moved over to 
+	kaffe/kaffevm/verify-uninit.h.
+	(BlockInfo, CHANGED, VISITED, IS_INSTRUCTION,
+	WIDE_MODDED, START_BLOCK, END_BLOCK, EXCEPTION_HANDLER)
+	Moved over to kaffe/kaffevm/verify-block.h.
+	(createBlock, copyBlockData, copyBlockState, freeBlock,
+	inWhichBlock) Moved over to
+	kaffe/kaffevm/verify-block.c.
+
 2004-02-29  Dalibor Topic <robilad at kaffe.org>
 
         * kaffe/kaffevm/verify-sigstack.c,
@@ -5,7 +37,7 @@
 	New files.
 
         * kaffe/kaffevm/Makefile.am:
-	(libkaffevm_la_SOURCES): Added verify-sugstack.c.
+	(libkaffevm_la_SOURCES): Added verify-sigstack.c.
         (noinst_HEADERS): Added verify-sigstackt.h.
 
         * kaffe/kaffevm/Makefile.in:
Index: kaffe/kaffe/kaffevm/Makefile.am
diff -u kaffe/kaffe/kaffevm/Makefile.am:1.52 kaffe/kaffe/kaffevm/Makefile.am:1.53
--- kaffe/kaffe/kaffevm/Makefile.am:1.52	Sun Feb 29 20:14:28 2004
+++ kaffe/kaffe/kaffevm/Makefile.am	Tue Mar  2 17:48:46 2004
@@ -93,6 +93,7 @@
 	gcFuncs.c \
 	gcRefs.c \
 	verify.c \
+	verify-block.c \
 	verify-debug.c \
 	verify-sigstack.c \
 	verify-uninit.c
@@ -138,6 +139,7 @@
 	threadData.h \
 	utf8const.h \
 	verify.h \
+	verify-block.h \
 	verify-debug.h \
 	verify-sigstack.h \
 	verify-uninit.h
Index: kaffe/kaffe/kaffevm/Makefile.in
diff -u kaffe/kaffe/kaffevm/Makefile.in:1.135 kaffe/kaffe/kaffevm/Makefile.in:1.136
--- kaffe/kaffe/kaffevm/Makefile.in:1.135	Sun Feb 29 20:14:28 2004
+++ kaffe/kaffe/kaffevm/Makefile.in	Tue Mar  2 17:48:46 2004
@@ -80,7 +80,8 @@
 	locks.lo lookup.lo object.lo readClass.lo sha-1.lo soft.lo \
 	stackTrace.lo stats.lo string.lo stringParsing.lo support.lo \
 	thread.lo utf8const.lo gcFuncs.lo gcRefs.lo verify.lo \
-	verify-debug.lo verify-sigstack.lo verify-uninit.lo
+	verify-block.lo verify-debug.lo verify-sigstack.lo \
+	verify-uninit.lo
 am__objects_1 = gc-mem.lo md.lo
 nodist_libkaffevm_la_OBJECTS = $(am__objects_1)
 libkaffevm_la_OBJECTS = $(am_libkaffevm_la_OBJECTS) \
@@ -109,6 +110,7 @@
 @AMDEP_TRUE@	./$(DEPDIR)/stringParsing.Plo \
 @AMDEP_TRUE@	./$(DEPDIR)/support.Plo ./$(DEPDIR)/thread.Plo \
 @AMDEP_TRUE@	./$(DEPDIR)/utf8const.Plo \
+ at AMDEP_TRUE@	./$(DEPDIR)/verify-block.Plo \
 @AMDEP_TRUE@	./$(DEPDIR)/verify-debug.Plo \
 @AMDEP_TRUE@	./$(DEPDIR)/verify-sigstack.Plo \
 @AMDEP_TRUE@	./$(DEPDIR)/verify-uninit.Plo \
@@ -437,6 +439,7 @@
 	gcFuncs.c \
 	gcRefs.c \
 	verify.c \
+	verify-block.c \
 	verify-debug.c \
 	verify-sigstack.c \
 	verify-uninit.c
@@ -482,6 +485,7 @@
 	threadData.h \
 	utf8const.h \
 	verify.h \
+	verify-block.h \
 	verify-debug.h \
 	verify-sigstack.h \
 	verify-uninit.h
@@ -593,6 +597,7 @@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/support.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/thread.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/utf8const.Plo at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/verify-block.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/verify-debug.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/verify-sigstack.Plo at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/verify-uninit.Plo at am__quote@
===================================================================
Checking out kaffe/kaffe/kaffevm/verify-block.c
RCS:  /home/cvs/kaffe/kaffe/kaffe/kaffevm/verify-block.c,v
VERS: 1.1
***************
--- /dev/null	Sun Aug  4 19:57:58 2002
+++ kaffe/kaffe/kaffevm/verify-block.c	Tue Mar  2 17:53:28 2004
@@ -0,0 +1,120 @@
+/*
+ * verify-block.c
+ *
+ * Copyright 2004
+ *   Kaffe.org contributors. See ChangeLog for details. All rights reserved.
+ *
+ * See the file "license.terms" for information on usage and redistribution
+ * of this file.
+ *
+ * Code for handing of blocks in the verifier.
+ */
+
+#include "verify-block.h"
+
+/*
+ * allocate memory for a block info and fill in with default values
+ */
+BlockInfo*
+createBlock(const Method* method)
+{
+	int i;
+	
+	BlockInfo* binfo = checkPtr((BlockInfo*)gc_malloc(sizeof(BlockInfo), GC_ALLOC_VERIFIER));
+	
+	binfo->startAddr   = 0;
+	binfo->status      = IS_INSTRUCTION | START_BLOCK;  /* not VISITED or CHANGED */
+	
+	/* allocate memory for locals */
+	if (method->localsz > 0) {
+		binfo->locals = checkPtr(gc_malloc(method->localsz * sizeof(Type), GC_ALLOC_VERIFIER));
+		
+		for (i = 0; i < method->localsz; i++) {
+			binfo->locals[i] = *TUNSTABLE;
+		}
+	} else {
+		binfo->locals = NULL;
+	}
+	
+	
+	/* allocate memory for operand stack */
+	binfo->stacksz = 0;
+	if (method->stacksz > 0) {
+		binfo->opstack = checkPtr(gc_malloc(method->stacksz * sizeof(Type), GC_ALLOC_VERIFIER));
+		
+		for (i = 0; i < method->stacksz; i++) {
+			binfo->opstack[i] = *TUNSTABLE;
+		}
+	} else {
+		binfo->opstack = NULL;
+	}
+	
+	return binfo;
+}
+
+/*
+ * frees the memory of a basic block
+ */
+void
+freeBlock(BlockInfo* binfo)
+{
+	if (binfo == NULL) return;
+	
+	if (binfo->locals != NULL)
+		gc_free(binfo->locals);
+	if (binfo->opstack != NULL)
+		gc_free(binfo->opstack);
+	
+	gc_free(binfo);
+}
+
+/*
+ * copies information from one stack of basic blocks to another
+ */
+void
+copyBlockData(const Method* method, BlockInfo* fromBlock, BlockInfo* toBlock)
+{
+	toBlock->startAddr = fromBlock->startAddr;
+	toBlock->lastAddr  = fromBlock->lastAddr;
+	
+	copyBlockState(method, fromBlock, toBlock);
+}
+
+/*
+ * copies the local variables, operand stack, status, and context
+ * from one block to another.
+ */
+void
+copyBlockState(const Method* method, BlockInfo* fromBlock, BlockInfo* toBlock)
+{
+	uint32 n;
+	
+	toBlock->status  = fromBlock->status;
+	
+	for (n = 0; n < method->localsz; n++) {
+		toBlock->locals[n] = fromBlock->locals[n];
+	}
+	
+	toBlock->stacksz = fromBlock->stacksz;
+	for (n = 0; n < method->stacksz; n++) {
+		toBlock->opstack[n] = fromBlock->opstack[n];
+	}
+}
+
+/*
+ * returns which block the given pc is in
+ */
+BlockInfo*
+inWhichBlock(uint32 pc, BlockInfo** blocks, uint32 numBlocks)
+{
+	uint32 i;
+	for (i = 0; i < numBlocks; i++) {
+		if (pc < blocks[i]->startAddr) continue;
+		if (pc <= blocks[i]->lastAddr) return blocks[i];
+	}
+	
+	/* shouldn't ever get here unless the specified PC is messed up */
+	DBG(VERIFY3, dprintf("inWhichBlock(...): pc = %d out of range...weird.\n", pc); );
+	
+	return NULL;
+}
===================================================================
Checking out kaffe/kaffe/kaffevm/verify-block.h
RCS:  /home/cvs/kaffe/kaffe/kaffe/kaffevm/verify-block.h,v
VERS: 1.1
***************
--- /dev/null	Sun Aug  4 19:57:58 2002
+++ kaffe/kaffe/kaffevm/verify-block.h	Tue Mar  2 17:53:29 2004
@@ -0,0 +1,84 @@
+/*
+ * verify-block.h
+ *
+ * Copyright 2004
+ *   Kaffe.org contributors. See ChangeLog for details. All rights reserved.
+ *
+ * See the file "license.terms" for information on usage and redistribution
+ * of this file.
+ *
+ * Interface to code for handing of blocks in the verifier.
+ */
+
+#if !defined(VERIFY_BLOCK_H)
+#define VERIFY_BLOCK_H
+
+#include "gtypes.h"
+#include "verify.h"
+
+/*
+ * basic block header information
+ */
+typedef struct block_info
+{
+        /* address of start of block */
+	uint32 startAddr;
+        uint32 lastAddr;  /* whether it be the address of a GOTO, etc. */
+	
+        /* status of block...
+	 * changed (needs to be re-evaluated), visited, etc. 
+	 */
+	uint32 status;
+	
+        /* array of local variables */
+	Type*  locals;
+	
+        /* simulated operand stack */
+	uint32 stacksz;
+	Type*  opstack;
+} BlockInfo;
+
+/* status flags for a basic block.
+ * these also pertain to the status[] array for the entire instruction array
+ */
+#define CHANGED            1
+#define VISITED            2
+#define IS_INSTRUCTION     4
+
+/* if the instruction is preceeded by WIDE */
+#define WIDE_MODDED        8
+
+/* used at the instruction status level to find basic blocks */
+#define START_BLOCK       16
+#define END_BLOCK         32
+
+#define EXCEPTION_HANDLER 64
+
+/*
+ * allocate memory for a block info and fill in with default values
+ */
+extern BlockInfo* createBlock(const Method* method);
+
+/*
+ * frees the memory of a basic block
+ */
+extern void freeBlock(BlockInfo* binfo);
+
+/*
+ * copies information from one stack of basic blocks to another
+ */
+extern void copyBlockData(const Method* method, BlockInfo* fromBlock, BlockInfo* toBlock);
+
+/*
+ * copies the local variables, operand stack, status, and context
+ * from one block to another.
+ */
+extern void copyBlockState(const Method* method, BlockInfo* fromBlock, BlockInfo* toBlock);
+
+/*
+ * returns which block the given pc is in
+ */
+extern BlockInfo* inWhichBlock(uint32 pc, BlockInfo** blocks, uint32 numBlocks);
+
+#endif /* !defined(VERIFY_BLOCK_H) */
+
Index: kaffe/kaffe/kaffevm/verify-debug.c
diff -u kaffe/kaffe/kaffevm/verify-debug.c:1.1 kaffe/kaffe/kaffevm/verify-debug.c:1.2
--- kaffe/kaffe/kaffevm/verify-debug.c:1.1	Sat Feb 28 18:44:27 2004
+++ kaffe/kaffe/kaffevm/verify-debug.c	Tue Mar  2 17:48:47 2004
@@ -12,6 +12,7 @@
 
 #include "debug.h"
 #include "verify.h"
+#include "verify-uninit.h"
 
 /* for debugging */
 #if !(defined(NDEBUG) || !defined(KAFFE_VMDEBUG))
Index: kaffe/kaffe/kaffevm/verify-debug.h
diff -u kaffe/kaffe/kaffevm/verify-debug.h:1.1 kaffe/kaffe/kaffevm/verify-debug.h:1.2
--- kaffe/kaffe/kaffevm/verify-debug.h:1.1	Sat Feb 28 18:44:27 2004
+++ kaffe/kaffe/kaffevm/verify-debug.h	Tue Mar  2 17:48:47 2004
@@ -10,8 +10,17 @@
  * Interface to the debugging code for the verifier.
  */
 
-#ifdef KAFFE_VMDEBUG
+#if !defined(VERIFY_DEBUG_H)
+#define VERIFY_DEBUG_H
+
+#include "classMethod.h"
+#include "verify.h"
+#include "verify-block.h"
+
+#if defined(KAFFE_VMDEBUG)
 extern void printInstruction(const int opcode);
 extern void printType(const Type*);
 extern void printBlock(const Method* method, const BlockInfo* binfo, const char* indent);
-#endif
+#endif /* defined(KAFFE_VMDEBUG) */
+
+#endif /* !defined(VERIFY_DEBUG_H) */
Index: kaffe/kaffe/kaffevm/verify-sigstack.h
diff -u kaffe/kaffe/kaffevm/verify-sigstack.h:1.1 kaffe/kaffe/kaffevm/verify-sigstack.h:1.2
--- kaffe/kaffe/kaffevm/verify-sigstack.h:1.1	Sun Feb 29 20:14:28 2004
+++ kaffe/kaffe/kaffevm/verify-sigstack.h	Tue Mar  2 17:48:47 2004
@@ -10,6 +10,9 @@
  * Interface to code for handing of signature stack in the verifier.
  */
 
+#if !defined(VERIFY_SIGSTACK_H)
+#define VERIFY_SIGSTACK_H
+
 /*
  * the sig stack is the stack of signatures that we have allocated memory for which
  * must be freed after verification.
@@ -25,3 +28,5 @@
 
 extern SigStack*          pushSig(SigStack* sigs, const char* sig);
 extern void               freeSigStack(SigStack* sigs);
+
+#endif /* !defined(VERIFY_SIGSTACK_H) */
Index: kaffe/kaffe/kaffevm/verify-uninit.h
diff -u kaffe/kaffe/kaffevm/verify-uninit.h:1.1 kaffe/kaffe/kaffevm/verify-uninit.h:1.2
--- kaffe/kaffe/kaffevm/verify-uninit.h:1.1	Sun Feb 29 18:42:46 2004
+++ kaffe/kaffe/kaffevm/verify-uninit.h	Tue Mar  2 17:48:47 2004
@@ -10,7 +10,27 @@
  * Interface to the code for handing of uninitialized type in the verifier.
  */
 
+#if !defined(VERIFY_UNINIT_H)
+#define VERIFY_UNINIT_H
+
 #include "verify.h"
+#include "verify-block.h"
+
+/*
+ * holds the list of uninitialized items.  that way, if we DUP some uninitialized
+ * reference, put it into a local variable, dup it again, etc, all will point to
+ * one item in this list, so when we <init> any of those we can init them all! :)
+ *
+ * doubly linked list to allow for easy removal of types
+ */
+typedef struct unitialized_types_double_list
+{
+	struct Type type;
+	
+	struct unitialized_types_double_list* prev;
+	struct unitialized_types_double_list* next;
+} UninitializedType;
+
 
 /*
  * checkUninit()
@@ -39,3 +59,5 @@
  */
 
 extern void freeUninits(UninitializedType* uninits);
+
+#endif /* !defined(VERIFY_UNINIT_H) */
Index: kaffe/kaffe/kaffevm/verify.c
diff -u kaffe/kaffe/kaffevm/verify.c:1.69 kaffe/kaffe/kaffevm/verify.c:1.70
--- kaffe/kaffe/kaffevm/verify.c:1.69	Sun Feb 29 20:14:28 2004
+++ kaffe/kaffe/kaffevm/verify.c	Tue Mar  2 17:48:47 2004
@@ -35,6 +35,7 @@
 #include "soft.h"
 
 #include "verify.h"
+#include "verify-block.h"
 #include "verify-debug.h"
 #include "verify-sigstack.h"
 #include "verify-uninit.h"
@@ -1017,13 +1018,6 @@
 /***********************************************************************************
  * Methods for Pass 3 Verification
  ***********************************************************************************/
-static BlockInfo*         createBlock(const Method* method);
-static void               copyBlockData(const Method* method, BlockInfo* fromBlock, BlockInfo* toBlock);
-static void               copyBlockState(const Method* method, BlockInfo* fromBlock, BlockInfo* toBlock);
-static void               freeBlock(BlockInfo* binfo);
-
-static BlockInfo*         inWhichBlock(uint32 pc, BlockInfo** blocks, uint32 numBlocks);
-
 static bool               verifyMethod(errorInfo* einfo, Method* method);
 static BlockInfo**        verifyMethod3a(errorInfo* einfo,
 					 Method* method,
@@ -4901,112 +4895,4 @@
 	}
 
 	return instanceof(t1->data.class, t2->data.class);
-}
-
-/*
- * allocate memory for a block info and fill in with default values
- */
-BlockInfo*
-createBlock(const Method* method)
-{
-	int i;
-	
-	BlockInfo* binfo = checkPtr((BlockInfo*)gc_malloc(sizeof(BlockInfo), GC_ALLOC_VERIFIER));
-	
-	binfo->startAddr   = 0;
-	binfo->status      = IS_INSTRUCTION | START_BLOCK;  /* not VISITED or CHANGED */
-	
-	/* allocate memory for locals */
-	if (method->localsz > 0) {
-		binfo->locals = checkPtr(gc_malloc(method->localsz * sizeof(Type), GC_ALLOC_VERIFIER));
-		
-		for (i = 0; i < method->localsz; i++) {
-			binfo->locals[i] = *TUNSTABLE;
-		}
-	} else {
-		binfo->locals = NULL;
-	}
-	
-	
-	/* allocate memory for operand stack */
-	binfo->stacksz = 0;
-	if (method->stacksz > 0) {
-		binfo->opstack = checkPtr(gc_malloc(method->stacksz * sizeof(Type), GC_ALLOC_VERIFIER));
-		
-		for (i = 0; i < method->stacksz; i++) {
-			binfo->opstack[i] = *TUNSTABLE;
-		}
-	} else {
-		binfo->opstack = NULL;
-	}
-	
-	return binfo;
-}
-
-/*
- * frees the memory of a basic block
- */
-void
-freeBlock(BlockInfo* binfo)
-{
-	if (binfo == NULL) return;
-	
-	if (binfo->locals != NULL)
-		gc_free(binfo->locals);
-	if (binfo->opstack != NULL)
-		gc_free(binfo->opstack);
-	
-	gc_free(binfo);
-}
-
-/*
- * copies information from one stack of basic blocks to another
- */
-void
-copyBlockData(const Method* method, BlockInfo* fromBlock, BlockInfo* toBlock)
-{
-	toBlock->startAddr = fromBlock->startAddr;
-	toBlock->lastAddr  = fromBlock->lastAddr;
-	
-	copyBlockState(method, fromBlock, toBlock);
-}
-
-/*
- * copies the local variables, operand stack, status, and context
- * from one block to another.
- */
-void
-copyBlockState(const Method* method, BlockInfo* fromBlock, BlockInfo* toBlock)
-{
-	uint32 n;
-	
-	toBlock->status  = fromBlock->status;
-	
-	for (n = 0; n < method->localsz; n++) {
-		toBlock->locals[n] = fromBlock->locals[n];
-	}
-	
-	toBlock->stacksz = fromBlock->stacksz;
-	for (n = 0; n < method->stacksz; n++) {
-		toBlock->opstack[n] = fromBlock->opstack[n];
-	}
-}
-
-/*
- * returns which block the given pc is in
- */
-static
-BlockInfo*
-inWhichBlock(uint32 pc, BlockInfo** blocks, uint32 numBlocks)
-{
-	uint32 i;
-	for (i = 0; i < numBlocks; i++) {
-		if (pc < blocks[i]->startAddr) continue;
-		if (pc <= blocks[i]->lastAddr) return blocks[i];
-	}
-	
-	/* shouldn't ever get here unless the specified PC is messed up */
-	DBG(VERIFY3, dprintf("inWhichBlock(...): pc = %d out of range...weird.\n", pc); );
-	
-	return NULL;
 }
Index: kaffe/kaffe/kaffevm/verify.h
diff -u kaffe/kaffe/kaffevm/verify.h:1.9 kaffe/kaffe/kaffevm/verify.h:1.10
--- kaffe/kaffe/kaffevm/verify.h:1.9	Sun Feb 29 20:14:28 2004
+++ kaffe/kaffe/kaffevm/verify.h	Tue Mar  2 17:48:47 2004
@@ -80,61 +80,6 @@
 #define IS_PRIMITIVE_TYPE(_TINFO) ((_TINFO)->tinfo & TINFO_PRIMITIVE)
 
 
-/*
- * holds the list of uninitialized items.  that way, if we DUP some uninitialized
- * reference, put it into a local variable, dup it again, etc, all will point to
- * one item in this list, so when we <init> any of those we can init them all! :)
- *
- * doubly linked list to allow for easy removal of types
- */
-typedef struct unitialized_types_double_list
-{
-	struct Type type;
-	
-	struct unitialized_types_double_list* prev;
-	struct unitialized_types_double_list* next;
-} UninitializedType;
-
-
-
-/*
- * basic block header information
- */
-typedef struct block_info
-{
-        /* address of start of block */
-	uint32 startAddr;
-        uint32 lastAddr;  /* whether it be the address of a GOTO, etc. */
-	
-        /* status of block...
-	 * changed (needs to be re-evaluated), visited, etc. 
-	 */
-	uint32 status;
-	
-        /* array of local variables */
-	Type*  locals;
-	
-        /* simulated operand stack */
-	uint32 stacksz;
-	Type*  opstack;
-} BlockInfo;
-
-/* status flags for a basic block.
- * these also pertain to the status[] array for the entire instruction array
- */
-#define CHANGED            1
-#define VISITED            2
-#define IS_INSTRUCTION     4
-
-/* if the instruction is preceeded by WIDE */
-#define WIDE_MODDED        8
-
-/* used at the instruction status level to find basic blocks */
-#define START_BLOCK       16
-#define END_BLOCK         32
-
-#define EXCEPTION_HANDLER 64
-
 void initVerifierPrimTypes(void);
 bool sameType(Type* t1, Type* t2);
 bool verify3(Hjava_lang_Class* class, errorInfo *einfo);




More information about the kaffe mailing list