From 1f4efe0a4fb230e587b72ab4e32ca4732161ce63 Mon Sep 17 00:00:00 2001 From: jespergravgaard Date: Tue, 17 Oct 2017 09:39:15 +0200 Subject: [PATCH] Added asm names to symbol table printout. --- src/main/java/dk/camelot64/kickc/TODO.txt | 1 + src/main/java/dk/camelot64/kickc/icl/Scope.java | 4 ++++ .../java/dk/camelot64/kickc/test/ref/bresenham.log | 12 ++++++------ .../java/dk/camelot64/kickc/test/ref/bresenham.sym | 12 ++++++------ .../dk/camelot64/kickc/test/ref/bresenhamarr.log | 12 ++++++------ .../dk/camelot64/kickc/test/ref/bresenhamarr.sym | 12 ++++++------ .../java/dk/camelot64/kickc/test/ref/constantmin.log | 10 +++++----- .../java/dk/camelot64/kickc/test/ref/constantmin.sym | 10 +++++----- src/main/java/dk/camelot64/kickc/test/ref/fibmem.log | 2 +- src/main/java/dk/camelot64/kickc/test/ref/fibmem.sym | 2 +- .../dk/camelot64/kickc/test/ref/flipper-rex2.log | 8 ++++---- .../dk/camelot64/kickc/test/ref/flipper-rex2.sym | 8 ++++---- .../dk/camelot64/kickc/test/ref/forclassicmin.log | 2 +- .../dk/camelot64/kickc/test/ref/forclassicmin.sym | 2 +- .../java/dk/camelot64/kickc/test/ref/forrangemin.log | 4 ++-- .../java/dk/camelot64/kickc/test/ref/forrangemin.sym | 4 ++-- src/main/java/dk/camelot64/kickc/test/ref/ifmin.log | 2 +- src/main/java/dk/camelot64/kickc/test/ref/ifmin.sym | 2 +- .../java/dk/camelot64/kickc/test/ref/iterarray.log | 2 +- .../java/dk/camelot64/kickc/test/ref/iterarray.sym | 2 +- .../java/dk/camelot64/kickc/test/ref/loopnest.log | 2 +- .../java/dk/camelot64/kickc/test/ref/loopnest.sym | 2 +- .../java/dk/camelot64/kickc/test/ref/loopnest2.log | 2 +- .../java/dk/camelot64/kickc/test/ref/loopnest2.sym | 2 +- .../java/dk/camelot64/kickc/test/ref/modglobal.log | 2 +- .../java/dk/camelot64/kickc/test/ref/modglobal.sym | 2 +- .../dk/camelot64/kickc/test/ref/modglobalmin.log | 2 +- .../dk/camelot64/kickc/test/ref/modglobalmin.sym | 2 +- .../java/dk/camelot64/kickc/test/ref/ptrtest.log | 6 +++--- .../java/dk/camelot64/kickc/test/ref/ptrtest.sym | 6 +++--- .../java/dk/camelot64/kickc/test/ref/ptrtestmin.log | 2 +- .../java/dk/camelot64/kickc/test/ref/ptrtestmin.sym | 2 +- .../java/dk/camelot64/kickc/test/ref/useglobal.log | 2 +- .../java/dk/camelot64/kickc/test/ref/useglobal.sym | 2 +- .../java/dk/camelot64/kickc/test/ref/voronoi.log | 12 ++++++------ .../java/dk/camelot64/kickc/test/ref/voronoi.sym | 12 ++++++------ .../java/dk/camelot64/kickc/test/ref/zpparammin.log | 4 ++-- .../java/dk/camelot64/kickc/test/ref/zpparammin.sym | 4 ++-- 38 files changed, 93 insertions(+), 88 deletions(-) diff --git a/src/main/java/dk/camelot64/kickc/TODO.txt b/src/main/java/dk/camelot64/kickc/TODO.txt index 6d2568e46..e41271878 100644 --- a/src/main/java/dk/camelot64/kickc/TODO.txt +++ b/src/main/java/dk/camelot64/kickc/TODO.txt @@ -57,6 +57,7 @@ Process/Code Structure Improvement + Make each phase return a separate object graph (allowing for keeeping the history in memory & performing rollbacks) Testing +- Test single passes by configuring compiler to only log ICL before & after the tested step! - Implement ICL syntax (printer & parser). Drop the JSON. - Test that the parse tree for specific KC syntax is as expected. Use a print function for the parse tree to generate output for comparison. - Test the ICL result of a specific phase on a specific ICL input. Create an ICL syntax for parsing directly to ICL and a printer for the syntax. diff --git a/src/main/java/dk/camelot64/kickc/icl/Scope.java b/src/main/java/dk/camelot64/kickc/icl/Scope.java index d7601a863..cacb8212b 100644 --- a/src/main/java/dk/camelot64/kickc/icl/Scope.java +++ b/src/main/java/dk/camelot64/kickc/icl/Scope.java @@ -316,6 +316,10 @@ public abstract class Scope implements Symbol { } if (symbol instanceof ConstantVar) { ConstantVar constantVar = (ConstantVar) symbol; + String asmName = constantVar.getAsmName(); + if (asmName != null) { + res.append(" " + asmName); + } res.append(" = " + constantVar.getValue().toString(program)); } res.append("\n"); diff --git a/src/main/java/dk/camelot64/kickc/test/ref/bresenham.log b/src/main/java/dk/camelot64/kickc/test/ref/bresenham.log index ee0d826f3..23534869a 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/bresenham.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/bresenham.log @@ -2060,9 +2060,9 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte[1000]) SCREEN -(const byte[1000]) SCREEN#0 = (word) 1024 +(const byte[1000]) SCREEN#0 SCREEN = (word) 1024 (byte) STAR -(const byte) STAR#0 = (byte) 81 +(const byte) STAR#0 STAR = (byte) 81 (void()) main() (label) main::@1 (label) main::@2 @@ -2083,18 +2083,18 @@ FINAL SYMBOL TABLE (byte) main::x#2 x zp ZP_BYTE:4 11.0 (byte) main::x0 (byte) main::x1 -(const byte) main::x1#0 = (byte) 39 +(const byte) main::x1#0 x1 = (byte) 39 (byte) main::xd -(const byte) main::xd#0 = (const byte) main::x1#0-(byte) 4 +(const byte) main::xd#0 xd = (const byte) main::x1#0-(byte) 4 (byte) main::y (byte) main::y#1 y zp ZP_BYTE:5 7.333333333333333 (byte) main::y#2 y zp ZP_BYTE:5 5.5 (byte) main::y#4 y zp ZP_BYTE:5 16.5 (byte) main::y0 (byte) main::y1 -(const byte) main::y1#0 = (byte) 24 +(const byte) main::y1#0 y1 = (byte) 24 (byte) main::yd -(const byte) main::yd#0 = (const byte) main::y1#0-(byte) 4 +(const byte) main::yd#0 yd = (const byte) main::y1#0-(byte) 4 zp ZP_PTR_BYTE:2 [ main::cursor#3 main::cursor#5 main::cursor#1 main::cursor#2 ] zp ZP_BYTE:4 [ main::x#2 main::x#1 ] diff --git a/src/main/java/dk/camelot64/kickc/test/ref/bresenham.sym b/src/main/java/dk/camelot64/kickc/test/ref/bresenham.sym index 92810ccf8..d7d580168 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/bresenham.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/bresenham.sym @@ -1,9 +1,9 @@ (label) @begin (label) @end (byte[1000]) SCREEN -(const byte[1000]) SCREEN#0 = (word) 1024 +(const byte[1000]) SCREEN#0 SCREEN = (word) 1024 (byte) STAR -(const byte) STAR#0 = (byte) 81 +(const byte) STAR#0 STAR = (byte) 81 (void()) main() (label) main::@1 (label) main::@2 @@ -24,18 +24,18 @@ (byte) main::x#2 x zp ZP_BYTE:4 11.0 (byte) main::x0 (byte) main::x1 -(const byte) main::x1#0 = (byte) 39 +(const byte) main::x1#0 x1 = (byte) 39 (byte) main::xd -(const byte) main::xd#0 = (const byte) main::x1#0-(byte) 4 +(const byte) main::xd#0 xd = (const byte) main::x1#0-(byte) 4 (byte) main::y (byte) main::y#1 y zp ZP_BYTE:5 7.333333333333333 (byte) main::y#2 y zp ZP_BYTE:5 5.5 (byte) main::y#4 y zp ZP_BYTE:5 16.5 (byte) main::y0 (byte) main::y1 -(const byte) main::y1#0 = (byte) 24 +(const byte) main::y1#0 y1 = (byte) 24 (byte) main::yd -(const byte) main::yd#0 = (const byte) main::y1#0-(byte) 4 +(const byte) main::yd#0 yd = (const byte) main::y1#0-(byte) 4 zp ZP_PTR_BYTE:2 [ main::cursor#3 main::cursor#5 main::cursor#1 main::cursor#2 ] zp ZP_BYTE:4 [ main::x#2 main::x#1 ] diff --git a/src/main/java/dk/camelot64/kickc/test/ref/bresenhamarr.log b/src/main/java/dk/camelot64/kickc/test/ref/bresenhamarr.log index 59da75572..5fb710992 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/bresenhamarr.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/bresenhamarr.log @@ -1669,7 +1669,7 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte) STAR -(const byte) STAR#0 = (byte) 81 +(const byte) STAR#0 STAR = (byte) 81 (byte) e (byte) e#1 reg byte y 11.0 (byte) e#2 reg byte y 22.0 @@ -1681,24 +1681,24 @@ FINAL SYMBOL TABLE (word) idx#3 idx zp ZP_WORD:2 11.0 (word) idx#5 idx zp ZP_WORD:2 16.5 (byte[1000]) screen -(const byte[1000]) screen#0 = (word) 1024 +(const byte[1000]) screen#0 screen = (word) 1024 (byte) x (byte) x#1 reg byte x 3.666666666666667 (byte) x#2 reg byte x 11.0 (byte) x0 (byte) x1 -(const byte) x1#0 = (byte) 39 +(const byte) x1#0 x1 = (byte) 39 (byte) xd -(const byte) xd#0 = (const byte) x1#0-(byte) 0 +(const byte) xd#0 xd = (const byte) x1#0-(byte) 0 (byte) y (byte) y#1 y zp ZP_BYTE:4 7.333333333333333 (byte) y#2 y zp ZP_BYTE:4 5.5 (byte) y#4 y zp ZP_BYTE:4 16.5 (byte) y0 (byte) y1 -(const byte) y1#0 = (byte) 24 +(const byte) y1#0 y1 = (byte) 24 (byte) yd -(const byte) yd#0 = (const byte) y1#0-(byte) 0 +(const byte) yd#0 yd = (const byte) y1#0-(byte) 0 zp ZP_WORD:2 [ idx#3 idx#5 idx#1 idx#2 ] reg byte x [ x#2 x#1 ] diff --git a/src/main/java/dk/camelot64/kickc/test/ref/bresenhamarr.sym b/src/main/java/dk/camelot64/kickc/test/ref/bresenhamarr.sym index c526ae43e..3039841f5 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/bresenhamarr.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/bresenhamarr.sym @@ -4,7 +4,7 @@ (label) @begin (label) @end (byte) STAR -(const byte) STAR#0 = (byte) 81 +(const byte) STAR#0 STAR = (byte) 81 (byte) e (byte) e#1 reg byte y 11.0 (byte) e#2 reg byte y 22.0 @@ -16,24 +16,24 @@ (word) idx#3 idx zp ZP_WORD:2 11.0 (word) idx#5 idx zp ZP_WORD:2 16.5 (byte[1000]) screen -(const byte[1000]) screen#0 = (word) 1024 +(const byte[1000]) screen#0 screen = (word) 1024 (byte) x (byte) x#1 reg byte x 3.666666666666667 (byte) x#2 reg byte x 11.0 (byte) x0 (byte) x1 -(const byte) x1#0 = (byte) 39 +(const byte) x1#0 x1 = (byte) 39 (byte) xd -(const byte) xd#0 = (const byte) x1#0-(byte) 0 +(const byte) xd#0 xd = (const byte) x1#0-(byte) 0 (byte) y (byte) y#1 y zp ZP_BYTE:4 7.333333333333333 (byte) y#2 y zp ZP_BYTE:4 5.5 (byte) y#4 y zp ZP_BYTE:4 16.5 (byte) y0 (byte) y1 -(const byte) y1#0 = (byte) 24 +(const byte) y1#0 y1 = (byte) 24 (byte) yd -(const byte) yd#0 = (const byte) y1#0-(byte) 0 +(const byte) yd#0 yd = (const byte) y1#0-(byte) 0 zp ZP_WORD:2 [ idx#3 idx#5 idx#1 idx#2 ] reg byte x [ x#2 x#1 ] diff --git a/src/main/java/dk/camelot64/kickc/test/ref/constantmin.log b/src/main/java/dk/camelot64/kickc/test/ref/constantmin.log index dcf4c6f36..55f15a134 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/constantmin.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/constantmin.log @@ -893,15 +893,15 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte*) BGCOL -(const byte*) BGCOL#0 = (const byte*) VIC#0+(byte) 16*(byte) 2+(byte) 1 +(const byte*) BGCOL#0 BGCOL = (const byte*) VIC#0+(byte) 16*(byte) 2+(byte) 1 (byte) RED -(const byte) RED#0 = (byte) 2 +(const byte) RED#0 RED = (byte) 2 (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (byte) STAR -(const byte) STAR#0 = (byte) 81 +(const byte) STAR#0 STAR = (byte) 81 (byte*) VIC -(const byte*) VIC#0 = (word) 53248 +(const byte*) VIC#0 VIC = (word) 53248 (void()) main() (label) main::@1 (label) main::@return diff --git a/src/main/java/dk/camelot64/kickc/test/ref/constantmin.sym b/src/main/java/dk/camelot64/kickc/test/ref/constantmin.sym index 9c4c36a77..03b875684 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/constantmin.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/constantmin.sym @@ -1,15 +1,15 @@ (label) @begin (label) @end (byte*) BGCOL -(const byte*) BGCOL#0 = (const byte*) VIC#0+(byte) 16*(byte) 2+(byte) 1 +(const byte*) BGCOL#0 BGCOL = (const byte*) VIC#0+(byte) 16*(byte) 2+(byte) 1 (byte) RED -(const byte) RED#0 = (byte) 2 +(const byte) RED#0 RED = (byte) 2 (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (byte) STAR -(const byte) STAR#0 = (byte) 81 +(const byte) STAR#0 STAR = (byte) 81 (byte*) VIC -(const byte*) VIC#0 = (word) 53248 +(const byte*) VIC#0 VIC = (word) 53248 (void()) main() (label) main::@1 (label) main::@return diff --git a/src/main/java/dk/camelot64/kickc/test/ref/fibmem.log b/src/main/java/dk/camelot64/kickc/test/ref/fibmem.log index c6fbcc09b..a9c767337 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/fibmem.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/fibmem.log @@ -941,7 +941,7 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte[15]) fibs -(const byte[15]) fibs#0 = (word) 4352 +(const byte[15]) fibs#0 fibs = (word) 4352 (void()) main() (byte~) main::$1 reg byte a 11.0 (byte~) main::$3 reg byte alu 22.0 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/fibmem.sym b/src/main/java/dk/camelot64/kickc/test/ref/fibmem.sym index 725a830a0..fada130a4 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/fibmem.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/fibmem.sym @@ -1,7 +1,7 @@ (label) @begin (label) @end (byte[15]) fibs -(const byte[15]) fibs#0 = (word) 4352 +(const byte[15]) fibs#0 fibs = (word) 4352 (void()) main() (byte~) main::$1 reg byte a 11.0 (byte~) main::$3 reg byte alu 22.0 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/flipper-rex2.log b/src/main/java/dk/camelot64/kickc/test/ref/flipper-rex2.log index fbb6ec282..afea86355 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/flipper-rex2.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/flipper-rex2.log @@ -6065,13 +6065,13 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte*) RASTER -(const byte*) RASTER#0 = (word) 53266 +(const byte*) RASTER#0 RASTER = (word) 53266 (byte[1000]) SCREEN -(const byte[1000]) SCREEN#0 = (word) 1024 +(const byte[1000]) SCREEN#0 SCREEN = (word) 1024 (byte[256]) buffer1 -(const byte[256]) buffer1#0 = (word) 4096 +(const byte[256]) buffer1#0 buffer1 = (word) 4096 (byte[256]) buffer2 -(const byte[256]) buffer2#0 = (word) 4352 +(const byte[256]) buffer2#0 buffer2 = (word) 4352 (void()) flip() (byte~) flip::$0 reg byte a 2002.0 (byte~) flip::$4 reg byte a 202.0 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/flipper-rex2.sym b/src/main/java/dk/camelot64/kickc/test/ref/flipper-rex2.sym index abe7d334d..f6aa08117 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/flipper-rex2.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/flipper-rex2.sym @@ -1,13 +1,13 @@ (label) @begin (label) @end (byte*) RASTER -(const byte*) RASTER#0 = (word) 53266 +(const byte*) RASTER#0 RASTER = (word) 53266 (byte[1000]) SCREEN -(const byte[1000]) SCREEN#0 = (word) 1024 +(const byte[1000]) SCREEN#0 SCREEN = (word) 1024 (byte[256]) buffer1 -(const byte[256]) buffer1#0 = (word) 4096 +(const byte[256]) buffer1#0 buffer1 = (word) 4096 (byte[256]) buffer2 -(const byte[256]) buffer2#0 = (word) 4352 +(const byte[256]) buffer2#0 buffer2 = (word) 4352 (void()) flip() (byte~) flip::$0 reg byte a 2002.0 (byte~) flip::$4 reg byte a 202.0 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/forclassicmin.log b/src/main/java/dk/camelot64/kickc/test/ref/forclassicmin.log index 9a4f39d83..1cebbb60c 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/forclassicmin.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/forclassicmin.log @@ -693,7 +693,7 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (void()) main() (label) main::@1 (label) main::@return diff --git a/src/main/java/dk/camelot64/kickc/test/ref/forclassicmin.sym b/src/main/java/dk/camelot64/kickc/test/ref/forclassicmin.sym index 20cdfacce..dad4e247b 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/forclassicmin.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/forclassicmin.sym @@ -2,7 +2,7 @@ (label) @begin (label) @end (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (void()) main() (label) main::@1 (label) main::@return diff --git a/src/main/java/dk/camelot64/kickc/test/ref/forrangemin.log b/src/main/java/dk/camelot64/kickc/test/ref/forrangemin.log index cf8b70c2e..574184f6c 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/forrangemin.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/forrangemin.log @@ -1081,9 +1081,9 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte*) SCREEN1 -(const byte*) SCREEN1#0 = (word) 1024 +(const byte*) SCREEN1#0 SCREEN1 = (word) 1024 (byte*) SCREEN2 -(const byte*) SCREEN2#0 = (word) 1280 +(const byte*) SCREEN2#0 SCREEN2 = (word) 1280 (void()) main() (label) main::@1 (label) main::@2 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/forrangemin.sym b/src/main/java/dk/camelot64/kickc/test/ref/forrangemin.sym index f2fe846cd..d196d5486 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/forrangemin.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/forrangemin.sym @@ -2,9 +2,9 @@ (label) @begin (label) @end (byte*) SCREEN1 -(const byte*) SCREEN1#0 = (word) 1024 +(const byte*) SCREEN1#0 SCREEN1 = (word) 1024 (byte*) SCREEN2 -(const byte*) SCREEN2#0 = (word) 1280 +(const byte*) SCREEN2#0 SCREEN2 = (word) 1280 (void()) main() (label) main::@1 (label) main::@2 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/ifmin.log b/src/main/java/dk/camelot64/kickc/test/ref/ifmin.log index 4b9c9f0f4..10e9c4036 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/ifmin.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/ifmin.log @@ -869,7 +869,7 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (void()) main() (label) main::@1 (label) main::@2 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/ifmin.sym b/src/main/java/dk/camelot64/kickc/test/ref/ifmin.sym index c491fe196..ee8c098cb 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/ifmin.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/ifmin.sym @@ -1,7 +1,7 @@ (label) @begin (label) @end (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (void()) main() (label) main::@1 (label) main::@2 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/iterarray.log b/src/main/java/dk/camelot64/kickc/test/ref/iterarray.log index ac50d00bc..02a2a97bd 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/iterarray.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/iterarray.log @@ -760,7 +760,7 @@ FINAL SYMBOL TABLE (label) main::@1 (label) main::@return (byte[16]) main::buf -(const byte[16]) main::buf#0 = (word) 4352 +(const byte[16]) main::buf#0 buf = (word) 4352 (byte) main::i (byte) main::i#1 reg byte x 16.5 (byte) main::i#2 reg byte x 14.666666666666666 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/iterarray.sym b/src/main/java/dk/camelot64/kickc/test/ref/iterarray.sym index 756ab6f0c..7f6b88a3e 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/iterarray.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/iterarray.sym @@ -5,7 +5,7 @@ (label) main::@1 (label) main::@return (byte[16]) main::buf -(const byte[16]) main::buf#0 = (word) 4352 +(const byte[16]) main::buf#0 buf = (word) 4352 (byte) main::i (byte) main::i#1 reg byte x 16.5 (byte) main::i#2 reg byte x 14.666666666666666 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/loopnest.log b/src/main/java/dk/camelot64/kickc/test/ref/loopnest.log index 7366a1541..8de7d7de4 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/loopnest.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/loopnest.log @@ -1128,7 +1128,7 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (void()) main() (label) main::@1 (label) main::@3 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/loopnest.sym b/src/main/java/dk/camelot64/kickc/test/ref/loopnest.sym index 1c01f44c3..52f299309 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/loopnest.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/loopnest.sym @@ -1,7 +1,7 @@ (label) @begin (label) @end (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (void()) main() (label) main::@1 (label) main::@3 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/loopnest2.log b/src/main/java/dk/camelot64/kickc/test/ref/loopnest2.log index 6a1a9c0db..015010617 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/loopnest2.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/loopnest2.log @@ -2729,7 +2729,7 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (void()) main() (label) main::@1 (label) main::@2 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/loopnest2.sym b/src/main/java/dk/camelot64/kickc/test/ref/loopnest2.sym index 68a7d1f9c..9b4d2839d 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/loopnest2.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/loopnest2.sym @@ -1,7 +1,7 @@ (label) @begin (label) @end (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (void()) main() (label) main::@1 (label) main::@2 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/modglobal.log b/src/main/java/dk/camelot64/kickc/test/ref/modglobal.log index 7071227e3..588b31b75 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/modglobal.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/modglobal.log @@ -1195,7 +1195,7 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte[256]) SCREEN -(const byte[256]) SCREEN#0 = (word) 1024 +(const byte[256]) SCREEN#0 SCREEN = (word) 1024 (byte) cnt (byte) cnt#1 reg byte x 0.75 (byte) cnt#12 reg byte x 4.0 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/modglobal.sym b/src/main/java/dk/camelot64/kickc/test/ref/modglobal.sym index 36dec70ac..c2ffd5274 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/modglobal.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/modglobal.sym @@ -1,7 +1,7 @@ (label) @begin (label) @end (byte[256]) SCREEN -(const byte[256]) SCREEN#0 = (word) 1024 +(const byte[256]) SCREEN#0 SCREEN = (word) 1024 (byte) cnt (byte) cnt#1 reg byte x 0.75 (byte) cnt#12 reg byte x 4.0 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/modglobalmin.log b/src/main/java/dk/camelot64/kickc/test/ref/modglobalmin.log index ec660cffe..6333e068d 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/modglobalmin.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/modglobalmin.log @@ -845,7 +845,7 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte[256]) SCREEN -(const byte[256]) SCREEN#0 = (word) 1024 +(const byte[256]) SCREEN#0 SCREEN = (word) 1024 (byte) cnt (byte) cnt#1 reg byte x 4.0 (byte) cnt#10 reg byte x 1.6 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/modglobalmin.sym b/src/main/java/dk/camelot64/kickc/test/ref/modglobalmin.sym index e392e93b4..b39281ab0 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/modglobalmin.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/modglobalmin.sym @@ -1,7 +1,7 @@ (label) @begin (label) @end (byte[256]) SCREEN -(const byte[256]) SCREEN#0 = (word) 1024 +(const byte[256]) SCREEN#0 SCREEN = (word) 1024 (byte) cnt (byte) cnt#1 reg byte x 4.0 (byte) cnt#10 reg byte x 1.6 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/ptrtest.log b/src/main/java/dk/camelot64/kickc/test/ref/ptrtest.log index 68872c4d7..cc1e2c124 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/ptrtest.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/ptrtest.log @@ -2926,7 +2926,7 @@ FINAL SYMBOL TABLE (label) lvalue::@2 (label) lvalue::@return (byte[1024]) lvalue::SCREEN -(const byte[1024]) lvalue::SCREEN#0 = (word) 1024 +(const byte[1024]) lvalue::SCREEN#0 SCREEN = (word) 1024 (byte) lvalue::i (byte) lvalue::i#1 reg byte x 22.0 (byte) lvalue::i#2 reg byte x 14.666666666666666 @@ -2935,7 +2935,7 @@ FINAL SYMBOL TABLE (label) lvaluevar::@2 (label) lvaluevar::@return (byte) lvaluevar::b -(const byte) lvaluevar::b#0 = (byte) 4 +(const byte) lvaluevar::b#0 b = (byte) 4 (byte) lvaluevar::i (byte) lvaluevar::i#1 reg byte x 22.0 (byte) lvaluevar::i#2 reg byte x 8.25 @@ -2952,7 +2952,7 @@ FINAL SYMBOL TABLE (label) rvalue::@2 (label) rvalue::@return (byte[1024]) rvalue::SCREEN -(const byte[1024]) rvalue::SCREEN#0 = (word) 1024 +(const byte[1024]) rvalue::SCREEN#0 SCREEN = (word) 1024 (byte) rvalue::b (byte) rvalue::b#0 reg byte a 20.0 (byte) rvalue::b#1 reg byte a 20.0 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/ptrtest.sym b/src/main/java/dk/camelot64/kickc/test/ref/ptrtest.sym index 7680f5396..af5788f79 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/ptrtest.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/ptrtest.sym @@ -5,7 +5,7 @@ (label) lvalue::@2 (label) lvalue::@return (byte[1024]) lvalue::SCREEN -(const byte[1024]) lvalue::SCREEN#0 = (word) 1024 +(const byte[1024]) lvalue::SCREEN#0 SCREEN = (word) 1024 (byte) lvalue::i (byte) lvalue::i#1 reg byte x 22.0 (byte) lvalue::i#2 reg byte x 14.666666666666666 @@ -14,7 +14,7 @@ (label) lvaluevar::@2 (label) lvaluevar::@return (byte) lvaluevar::b -(const byte) lvaluevar::b#0 = (byte) 4 +(const byte) lvaluevar::b#0 b = (byte) 4 (byte) lvaluevar::i (byte) lvaluevar::i#1 reg byte x 22.0 (byte) lvaluevar::i#2 reg byte x 8.25 @@ -31,7 +31,7 @@ (label) rvalue::@2 (label) rvalue::@return (byte[1024]) rvalue::SCREEN -(const byte[1024]) rvalue::SCREEN#0 = (word) 1024 +(const byte[1024]) rvalue::SCREEN#0 SCREEN = (word) 1024 (byte) rvalue::b (byte) rvalue::b#0 reg byte a 20.0 (byte) rvalue::b#1 reg byte a 20.0 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/ptrtestmin.log b/src/main/java/dk/camelot64/kickc/test/ref/ptrtestmin.log index d33dea904..9ae93abea 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/ptrtestmin.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/ptrtestmin.log @@ -699,7 +699,7 @@ FINAL SYMBOL TABLE (label) main::@2 (label) main::@return (byte[1024]) main::SCREEN -(const byte[1024]) main::SCREEN#0 = (word) 1024 +(const byte[1024]) main::SCREEN#0 SCREEN = (word) 1024 (byte) main::b (byte) main::b#0 reg byte a 110.0 (byte) main::i diff --git a/src/main/java/dk/camelot64/kickc/test/ref/ptrtestmin.sym b/src/main/java/dk/camelot64/kickc/test/ref/ptrtestmin.sym index da11c0222..0653fadba 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/ptrtestmin.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/ptrtestmin.sym @@ -5,7 +5,7 @@ (label) main::@2 (label) main::@return (byte[1024]) main::SCREEN -(const byte[1024]) main::SCREEN#0 = (word) 1024 +(const byte[1024]) main::SCREEN#0 SCREEN = (word) 1024 (byte) main::b (byte) main::b#0 reg byte a 110.0 (byte) main::i diff --git a/src/main/java/dk/camelot64/kickc/test/ref/useglobal.log b/src/main/java/dk/camelot64/kickc/test/ref/useglobal.log index cc48c56d2..0de36a9b6 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/useglobal.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/useglobal.log @@ -306,7 +306,7 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (void()) main() (label) main::@return diff --git a/src/main/java/dk/camelot64/kickc/test/ref/useglobal.sym b/src/main/java/dk/camelot64/kickc/test/ref/useglobal.sym index be0e509ff..82aec256f 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/useglobal.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/useglobal.sym @@ -1,7 +1,7 @@ (label) @begin (label) @end (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (void()) main() (label) main::@return diff --git a/src/main/java/dk/camelot64/kickc/test/ref/voronoi.log b/src/main/java/dk/camelot64/kickc/test/ref/voronoi.log index eac7a2ca1..de7b09dd8 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/voronoi.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/voronoi.log @@ -11713,17 +11713,17 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte*) COLORS -(const byte*) COLORS#0 = (word) 55296 +(const byte*) COLORS#0 COLORS = (word) 55296 (byte[256]) COLS -(const byte[256]) COLS#0 = (word) 4608 +(const byte[256]) COLS#0 COLS = (word) 4608 (byte) FILL -(const byte) FILL#0 = (byte) 230 +(const byte) FILL#0 FILL = (byte) 230 (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (byte[256]) XPOS -(const byte[256]) XPOS#0 = (word) 4096 +(const byte[256]) XPOS#0 XPOS = (word) 4096 (byte[256]) YPOS -(const byte[256]) YPOS#0 = (word) 4352 +(const byte[256]) YPOS#0 YPOS = (word) 4352 (void()) addpoint((byte) addpoint::x , (byte) addpoint::y , (byte) addpoint::c) (label) addpoint::@return (byte) addpoint::c diff --git a/src/main/java/dk/camelot64/kickc/test/ref/voronoi.sym b/src/main/java/dk/camelot64/kickc/test/ref/voronoi.sym index b75c2d7d7..995e65552 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/voronoi.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/voronoi.sym @@ -1,17 +1,17 @@ (label) @begin (label) @end (byte*) COLORS -(const byte*) COLORS#0 = (word) 55296 +(const byte*) COLORS#0 COLORS = (word) 55296 (byte[256]) COLS -(const byte[256]) COLS#0 = (word) 4608 +(const byte[256]) COLS#0 COLS = (word) 4608 (byte) FILL -(const byte) FILL#0 = (byte) 230 +(const byte) FILL#0 FILL = (byte) 230 (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (byte[256]) XPOS -(const byte[256]) XPOS#0 = (word) 4096 +(const byte[256]) XPOS#0 XPOS = (word) 4096 (byte[256]) YPOS -(const byte[256]) YPOS#0 = (word) 4352 +(const byte[256]) YPOS#0 YPOS = (word) 4352 (void()) addpoint((byte) addpoint::x , (byte) addpoint::y , (byte) addpoint::c) (label) addpoint::@return (byte) addpoint::c diff --git a/src/main/java/dk/camelot64/kickc/test/ref/zpparammin.log b/src/main/java/dk/camelot64/kickc/test/ref/zpparammin.log index 9b81eb2d8..432d08afd 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/zpparammin.log +++ b/src/main/java/dk/camelot64/kickc/test/ref/zpparammin.log @@ -1966,9 +1966,9 @@ FINAL SYMBOL TABLE (label) @begin (label) @end (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (byte*) SCREEN2 -(const byte*) SCREEN2#0 = (word) 1024+(byte) 40 +(const byte*) SCREEN2#0 SCREEN2 = (word) 1024+(byte) 40 (void()) main() (byte~) main::$0 reg byte x 7.333333333333333 (byte~) main::$1 reg byte a 7.333333333333333 diff --git a/src/main/java/dk/camelot64/kickc/test/ref/zpparammin.sym b/src/main/java/dk/camelot64/kickc/test/ref/zpparammin.sym index 093775bd4..843bc89a5 100644 --- a/src/main/java/dk/camelot64/kickc/test/ref/zpparammin.sym +++ b/src/main/java/dk/camelot64/kickc/test/ref/zpparammin.sym @@ -1,9 +1,9 @@ (label) @begin (label) @end (byte*) SCREEN -(const byte*) SCREEN#0 = (word) 1024 +(const byte*) SCREEN#0 SCREEN = (word) 1024 (byte*) SCREEN2 -(const byte*) SCREEN2#0 = (word) 1024+(byte) 40 +(const byte*) SCREEN2#0 SCREEN2 = (word) 1024+(byte) 40 (void()) main() (byte~) main::$0 reg byte x 7.333333333333333 (byte~) main::$1 reg byte a 7.333333333333333