* src/vm/jit/jit.h (basicblock): Changed type of iinstr to
authoredwin <none@none>
Tue, 5 Sep 2006 16:12:09 +0000 (16:12 +0000)
committeredwin <none@none>
Tue, 5 Sep 2006 16:12:09 +0000 (16:12 +0000)
new_instruction *.
* src/vm/jit/stack.c (new_stack_analyse): Removed obsolete casts.
* src/vm/jit/show.c (new_show_basicblock): Likewise.
* src/vm/jit/verify/typecheck.c (verify_basic_block): Likewise.
* src/vm/jit/allocator/simplereg.c (new_allocate_scratch_registers):
Likewise.
* src/vm/jit/parse.c (new_parse): Likewise.
* src/vm/jit/x86_64/codegen.c (new_parse): Likewise.

--HG--
branch : new_instruction_format

src/vm/jit/allocator/simplereg.c
src/vm/jit/jit.h
src/vm/jit/parse.c
src/vm/jit/show.c
src/vm/jit/stack.c
src/vm/jit/verify/typecheck.c
src/vm/jit/x86_64/codegen.c

index 15a12c80b00f06d2fedde44adb4231383da92ef1..0b28864ac97930d7a09fc8de52cd38c9eb4ad9fb 100644 (file)
@@ -32,7 +32,7 @@
             Michael Starzinger
             Edwin Steiner
 
-   $Id: simplereg.c 5317 2006-09-05 12:29:16Z edwin $
+   $Id: simplereg.c 5321 2006-09-05 16:12:09Z edwin $
 
 */
 
@@ -1211,7 +1211,7 @@ static void new_allocate_scratch_registers(jitdata *jd)
 
        while (bptr != NULL) {
                if (bptr->flags >= BBREACHED) {
-                       iptr = /* XXX */ (new_instruction *) bptr->iinstr;
+                       iptr = bptr->iinstr;
                        len = bptr->icount;
 
                        while (--len >= 0)  {
index 8b2ed99f8d6d98fcc43c8ba12ba53dd16aa87e3a..166b2e8ffb63618d6d353af7d1cde76969fa3d39 100644 (file)
@@ -30,7 +30,7 @@
    Changes: Christian Thalinger
                        Edwin Steiner
 
-   $Id: jit.h 5318 2006-09-05 12:42:12Z edwin $
+   $Id: jit.h 5321 2006-09-05 16:12:09Z edwin $
 
 */
 
@@ -412,7 +412,7 @@ struct basicblock {
        s4            flags;        /* used during stack analysis, init with -1   */
        s4            bitflags;     /* OR of BBFLAG_... constants, init with 0    */
        s4            type;         /* basic block type (std, xhandler, subroutine*/
-       instruction  *iinstr;       /* pointer to intermediate code instructions  */
+       new_instruction  *iinstr;       /* pointer to intermediate code instructions  */
        s4            icount;       /* number of intermediate code instructions   */
        s4            mpc;          /* machine code pc at start of block          */
        stackptr      instack;      /* stack at begin of basic block              */
index 19b2bf3b5417dac3fe2c9716a5c947135693f836..69c1498370dd210a1afea4329d2598286748b7d5 100644 (file)
@@ -31,7 +31,7 @@
             Joseph Wenninger
             Christian Thalinger
 
-   $Id: parse.c 5302 2006-09-05 10:37:26Z edwin $
+   $Id: parse.c 5321 2006-09-05 16:12:09Z edwin $
 
 */
 
@@ -1303,7 +1303,7 @@ invoke_method:
        if (!jd->new_basicblockindex[0] || (jd->new_basicblockindex[0] > 1)) {
                BASICBLOCK_INIT(bptr, m);
 
-               bptr->iinstr = /* XXX */ (instruction *) jd->new_instructions;
+               bptr->iinstr = jd->new_instructions;
                /* bptr->icount is set when the next block is allocated */
 
                bptr++;
@@ -1329,9 +1329,9 @@ invoke_method:
 
                        BASICBLOCK_INIT(bptr, m);
 
-                       bptr->iinstr = /* XXX */ (instruction *) (jd->new_instructions + (jd->new_basicblockindex[p] >> 1));
+                       bptr->iinstr = jd->new_instructions + (jd->new_basicblockindex[p] >> 1);
                        if (b_count) {
-                               bptr[-1].icount = /*XXX*/ (new_instruction *)bptr->iinstr - (new_instruction*) bptr[-1].iinstr;
+                               bptr[-1].icount = bptr->iinstr - bptr[-1].iinstr;
                        }
                        /* bptr->icount is set when the next block is allocated */
 
@@ -1346,7 +1346,7 @@ invoke_method:
        /* set instruction count of last real block */
 
        if (b_count) {
-               bptr[-1].icount = (jd->new_instructions + jd->new_instructioncount) - /* XXX */ (new_instruction *) bptr[-1].iinstr;
+               bptr[-1].icount = (jd->new_instructions + jd->new_instructioncount) - bptr[-1].iinstr;
        }
 
        /* allocate additional block at end */
index 76a96da9e4116ae6371041aa68c22e8f5c1bd791..bb5d9b65f6bca0ef986d8c78958310ef2114f156 100644 (file)
@@ -416,7 +416,7 @@ void new_show_basicblock(jitdata *jd, basicblock *bptr, int stage)
                        printf("\n");
                }
 
-               iptr = /*XXX*/ (new_instruction *) bptr->iinstr;
+               iptr = bptr->iinstr;
 
                for (i = 0; i < bptr->icount; i++, iptr++) {
                        printf("%4d:  ", iptr->line);
index 521fcf455aaf47e1f78b091b05abbfd9c5f88532..839508b740ceddbc41668120d93c16a60fa640e7 100644 (file)
@@ -30,7 +30,7 @@
             Christian Thalinger
             Christian Ullrich
 
-   $Id: stack.c 5311 2006-09-05 11:40:03Z edwin $
+   $Id: stack.c 5321 2006-09-05 16:12:09Z edwin $
 
 */
 
@@ -464,7 +464,7 @@ bool new_stack_analyse(jitdata *jd)
 
                        /* get the last instruction of the block */
 
-                       iptr = /* XXX */ (new_instruction *) bptr->iinstr + (bptr->icount - 1);
+                       iptr = bptr->iinstr + (bptr->icount - 1);
 
                        switch (iptr->opc) {
                                /* instruction stopping control flow */
@@ -594,7 +594,7 @@ bool new_stack_analyse(jitdata *jd)
                                superblockend = false;
                                bptr->flags = BBFINISHED;
                                len = bptr->icount;
-                               iptr = /* XXX */ (new_instruction *) bptr->iinstr;
+                               iptr = bptr->iinstr;
                                b_index = bptr - jd->new_basicblocks;
 
                                /* reset variables for dependency checking */
index f3999552cdb156d376358918ffef847b8cbb1acf..8faa8da01628fdf7fb1e47704fc2ca1f9cab3bbb 100644 (file)
@@ -28,7 +28,7 @@
 
    Changes: Christian Thalinger
 
-   $Id: typecheck.c 5317 2006-09-05 12:29:16Z edwin $
+   $Id: typecheck.c 5321 2006-09-05 16:12:09Z edwin $
 
 */
 
@@ -1667,7 +1667,7 @@ verify_basic_block(verifier_state *state)
 
        /* loop over the instructions */
        len = state->bptr->icount;
-       state->iptr = /* XXX */ (new_instruction *) state->bptr->iinstr;
+       state->iptr = state->bptr->iinstr;
        while (--len >= 0)  {
                TYPECHECK_COUNT(stat_ins);
 
index 9c46e5b2e2b0a125f918d967f78d0c9764b357d0..05a064ec39f622f76df4cebb830c8a4400c0d192 100644 (file)
@@ -30,7 +30,7 @@
    Changes: Christian Ullrich
             Edwin Steiner
 
-   $Id: codegen.c 5318 2006-09-05 12:42:12Z edwin $
+   $Id: codegen.c 5321 2006-09-05 16:12:09Z edwin $
 
 */
 
@@ -449,7 +449,7 @@ bool codegen(jitdata *jd)
                len = bptr->icount;
                currentline = 0;
 
-               for (iptr = /* XXX */ (new_instruction *) bptr->iinstr; len > 0; len--, iptr++) {
+               for (iptr = bptr->iinstr; len > 0; len--, iptr++) {
                        if (iptr->line != currentline) {
                                dseg_addlinenumber(cd, iptr->line);
                                currentline = iptr->line;