From 6b79ecc537152bfa26f34be90f8435bd26c48155 Mon Sep 17 00:00:00 2001 From: jespergravgaard Date: Fri, 29 Dec 2017 16:05:27 +0100 Subject: [PATCH] Implemented all fast multiply tables. --- .../java/dk/camelot64/kickc/Compiler.java | 2 + .../kickc/fragment/AsmFragmentManager.java | 2 +- .../asm/vbuaa_eq__deref_pbuz1_then_la1.asm | 3 + .../kickc/fragment/asm/vwuz1=_word_pbuz1.asm | 1 + .../java/dk/camelot64/kickc/test/multiply.kc | 97 +- .../dk/camelot64/kickc/test/ref/multiply.asm | 291 +- .../dk/camelot64/kickc/test/ref/multiply.cfg | 212 +- .../dk/camelot64/kickc/test/ref/multiply.log | 4742 +++++++++++++---- .../dk/camelot64/kickc/test/ref/multiply.sym | 145 +- 9 files changed, 4294 insertions(+), 1201 deletions(-) create mode 100644 src/main/java/dk/camelot64/kickc/fragment/asm/vbuaa_eq__deref_pbuz1_then_la1.asm create mode 100644 src/main/java/dk/camelot64/kickc/fragment/asm/vwuz1=_word_pbuz1.asm diff --git a/src/main/java/dk/camelot64/kickc/Compiler.java b/src/main/java/dk/camelot64/kickc/Compiler.java index ebe137149..77f3c7c07 100644 --- a/src/main/java/dk/camelot64/kickc/Compiler.java +++ b/src/main/java/dk/camelot64/kickc/Compiler.java @@ -44,6 +44,8 @@ public class Compiler { pass5GenerateAndOptimizeAsm(); return program; } catch (Exception e) { + System.out.println("EXCEPTION DURING COMPILE "+e.getMessage()); + System.out.println(getLog().toString()); throw e; } } diff --git a/src/main/java/dk/camelot64/kickc/fragment/AsmFragmentManager.java b/src/main/java/dk/camelot64/kickc/fragment/AsmFragmentManager.java index f708cea66..ba5de9d9d 100644 --- a/src/main/java/dk/camelot64/kickc/fragment/AsmFragmentManager.java +++ b/src/main/java/dk/camelot64/kickc/fragment/AsmFragmentManager.java @@ -20,7 +20,7 @@ import java.util.regex.Pattern; */ public class AsmFragmentManager { - static boolean verboseFragmentLog = false; + static boolean verboseFragmentLog = true; /** * Cache for fragment files. Maps signature to the parsed file. diff --git a/src/main/java/dk/camelot64/kickc/fragment/asm/vbuaa_eq__deref_pbuz1_then_la1.asm b/src/main/java/dk/camelot64/kickc/fragment/asm/vbuaa_eq__deref_pbuz1_then_la1.asm new file mode 100644 index 000000000..b9da71cdf --- /dev/null +++ b/src/main/java/dk/camelot64/kickc/fragment/asm/vbuaa_eq__deref_pbuz1_then_la1.asm @@ -0,0 +1,3 @@ +ldy #0 +cmp ({z1}),y +beq {la1} diff --git a/src/main/java/dk/camelot64/kickc/fragment/asm/vwuz1=_word_pbuz1.asm b/src/main/java/dk/camelot64/kickc/fragment/asm/vwuz1=_word_pbuz1.asm new file mode 100644 index 000000000..2f6b2d60f --- /dev/null +++ b/src/main/java/dk/camelot64/kickc/fragment/asm/vwuz1=_word_pbuz1.asm @@ -0,0 +1 @@ +// do nothing \ No newline at end of file diff --git a/src/test/java/dk/camelot64/kickc/test/multiply.kc b/src/test/java/dk/camelot64/kickc/test/multiply.kc index 5aca12bad..930d7bded 100644 --- a/src/test/java/dk/camelot64/kickc/test/multiply.kc +++ b/src/test/java/dk/camelot64/kickc/test/multiply.kc @@ -2,6 +2,8 @@ // See http://codebase64.org/doku.php?id=base:seriously_fast_multiplication // Utilizes the fact that a*b = ((a+b)/2)^2 - ((a-b)/2)^2 +import "print.kc" + byte* BGCOL = $d021; void main() { @@ -10,32 +12,59 @@ void main() { mul_tables_compare(); } -// mul_sqr tables will contain f(x)=int(x*x/4). -byte[512] mul_sqr_lo; -byte[512] mul_sqr_hi; +// mul_sqr tables will contain f(x)=int(x*x/4) and g(x) = f(x-255). +// f(x) = >(( x * x )/4) +byte[512] mul_sqr1_hi; +// g(x) = >((( x - 255) * ( x - 255 ))/4) +byte[512] mul_sqr2_hi; // Initialize the mul_sqr multiplication tables with f(x)=int(x*x/4) void init_mul_tables() { - // If f(x) = x*x/4 then f(x+1) = f(x) + x/2 + 1/4 + // Fill mul_sqr1 = f(x) = int(x*x/4): If f(x) = x*x/4 then f(x+1) = f(x) + x/2 + 1/4 word sqr = 0; // sqr = (x*x)/4 byte x_2 = 0; // x/2 byte c = 0; // Counter used for determining x%2==0 - byte* sqr_hi = mul_sqr_hi+1; - for(byte* sqr_lo = mul_sqr_lo+1; sqr_lo!=mul_sqr_lo+512; sqr_lo++) { + byte* sqr1_hi = mul_sqr1_hi+1; + for(byte* sqr1_lo = mul_sqr1_lo+1; sqr1_lo!=mul_sqr1_lo+512; sqr1_lo++) { if((++c&1)==0) { x_2++; // increase i/2 on even numbers sqr++; // sqr++ on even numbers because 1 = 2*1/4 (from the two previous numbers) + 1/2 (half of the previous uneven number) } - *sqr_lo = sqr; + *sqr1_lo = sqr; sqr = sqr + x_2; // sqr = sqr + i/2 (when uneven the 1/2 is not added here - see above) } - + // Fill mul_sqr2 = g(x) = f(x-255) : If x-255<0 then g(x)=f(255-x) (because x*x = -x*-x) + // g(0) = f(255), g(1) = f(254), ..., g(254) = f(1), g(255) = f(0), g(256) = f(1), ..., g(510) = f(255), g(511) = f(256) + byte x_255 = (byte)-1; //Start with g(0)=f(255) + byte dir = $ff; // Decrease or increase x_255 - initially we decrease + byte* sqr2_hi = mul_sqr2_hi; + for(byte* sqr2_lo = mul_sqr2_lo; sqr2_lo!=mul_sqr2_lo+511; sqr2_lo++) { + *sqr2_lo = mul_sqr1_lo[x_255]; + *sqr2_hi++ = mul_sqr1_hi[x_255]; + x_255 = x_255 + dir; + if(x_255==0) { + dir = 1; // when x_255=0 then start counting up + } + } + // Set the very last value g(511) = f(256) + *(mul_sqr2_lo+511) = *(mul_sqr1_lo+256); + *(mul_sqr2_hi+511) = *(mul_sqr1_hi+256); } // ASM based multiplication tables -byte[512] asm_mul_sqr_lo; -byte[512] asm_mul_sqr_hi; +// <(( x * x )/4) +byte[512] asm_mul_sqr1_lo; +// >(( x * x )/4) +byte[512] asm_mul_sqr1_hi; +// <((( x - 255) * ( x - 255 ))/4) +byte[512] asm_mul_sqr2_lo; +// >((( x - 255) * ( x - 255 ))/4) +byte[512] asm_mul_sqr2_hi; // Initialize the multiplication tables using ASM code from // http://codebase64.org/doku.php?id=base:seriously_fast_multiplication void init_mul_tables_asm() { @@ -47,7 +76,7 @@ void init_mul_tables_asm() { tya adc #$00 ml1: - sta asm_mul_sqr_hi,x + sta asm_mul_sqr1_hi,x tay cmp #$40 txa @@ -57,28 +86,52 @@ void init_mul_tables_asm() { sta ml9+1 inx ml0: - sta asm_mul_sqr_lo,x + sta asm_mul_sqr1_lo,x bne lb1 inc ml0+2 inc ml1+2 clc iny bne lb1 + ldx #$00 + ldy #$ff + !: + lda asm_mul_sqr1_hi+1,x + sta asm_mul_sqr2_hi+$100,x + lda asm_mul_sqr1_hi,x + sta asm_mul_sqr2_hi,y + lda asm_mul_sqr1_lo+1,x + sta asm_mul_sqr2_lo+$100,x + lda asm_mul_sqr1_lo,x + sta asm_mul_sqr2_lo,y + dey + inx + bne !- } + // Ensure the ASM tables are not detected as unused by the optimizer + byte* mem = $ff; + *mem = *asm_mul_sqr1_lo; + *mem = *asm_mul_sqr1_hi; + *mem = *asm_mul_sqr2_lo; + *mem = *asm_mul_sqr2_hi; + } // Compare the ASM-based mul tables with the KC-based mul tables // Red screen on failure - green on success void mul_tables_compare() { - *BGCOL = 5; - for( byte i: 0..255) { - if(mul_sqr_lo[i] != asm_mul_sqr_lo[i]) - *BGCOL = 2; - if((mul_sqr_hi+$100)[i] != (asm_mul_sqr_hi+$100)[i]) - *BGCOL = 2; - if(mul_sqr_lo[i] != asm_mul_sqr_lo[i]) - *BGCOL = 2; - if((mul_sqr_hi+$100)[i] != (asm_mul_sqr_hi+$100)[i]) + *BGCOL = 5; + byte* asm_sqr = asm_mul_sqr1_lo; + for( byte* kc_sqr=mul_sqr1_lo; kc_sqrasm_mul_sqr1_lo + sta asm_sqr+1 + lda #mul_sqr1_lo + sta kc_sqr+1 b1: - lda mul_sqr_lo,x - cmp asm_mul_sqr_lo,x + ldy #0 + lda (kc_sqr),y + cmp (asm_sqr),y beq b2 lda #2 sta BGCOL + jsr print_cls + lda #<$400 + sta char_cursor + lda #>$400 + sta char_cursor+1 + lda #str + sta print_str.str+1 + jsr print_str + jsr print_word + lda #str1 + sta print_str.str+1 + jsr print_str + lda kc_sqr + sta print_word.w + lda kc_sqr+1 + sta print_word.w+1 + jsr print_word + breturn: + rts b2: - lda mul_sqr_hi+$100,x - cmp asm_mul_sqr_hi+$100,x - beq b3 - lda #2 - sta BGCOL - b3: - lda mul_sqr_lo,x - cmp asm_mul_sqr_lo,x - beq b4 - lda #2 - sta BGCOL - b4: - lda mul_sqr_hi+$100,x - cmp asm_mul_sqr_hi+$100,x - beq b5 - lda #2 - sta BGCOL - b5: - inx - cpx #0 + inc asm_sqr + bne !+ + inc asm_sqr+1 + !: + inc kc_sqr + bne !+ + inc kc_sqr+1 + !: + lda kc_sqr+1 + cmp #>mul_sqr1_lo+$200*4 + bcc b1 + bne !+ + lda kc_sqr + cmp #$400 + sta char_cursor+1 + jmp breturn + str: .text "mul table mismatch at @" + str1: .text " / @" +} +print_word: { + .label w = 4 + lda w+1 + tax + jsr print_byte + lda w + tax + jsr print_byte + rts +} +print_byte: { + txa + lsr + lsr + lsr + lsr + tay + lda hextab,y + jsr print_char + txa + and #$f + tax + lda hextab,x + jsr print_char + rts + hextab: .byte '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f' +} +print_char: { + ldy #0 + sta (char_cursor),y + inc char_cursor + bne !+ + inc char_cursor+1 + !: + rts +} +print_str: { + .label str = 8 + b1: + ldy #0 + lda (str),y + cmp #'@' + bne b2 + rts + b2: + ldy #0 + lda (str),y + sta (char_cursor),y + inc char_cursor + bne !+ + inc char_cursor+1 + !: + inc str + bne !+ + inc str+1 + !: + jmp b1 +} +print_cls: { + .label sc = 6 + lda #<$400 + sta sc + lda #>$400 + sta sc+1 + b1: + ldy #0 + lda #' ' + sta (sc),y + inc sc + bne !+ + inc sc+1 + !: + lda sc+1 + cmp #>$400+$3e8 + bne b1 + lda sc + cmp #<$400+$3e8 bne b1 rts } init_mul_tables_asm: { + .const mem = $ff ldx #0 txa .byte $c9 @@ -55,7 +175,7 @@ init_mul_tables_asm: { tya adc #0 ml1: - sta asm_mul_sqr_hi,x + sta asm_mul_sqr1_hi,x tay cmp #$40 txa @@ -65,30 +185,55 @@ init_mul_tables_asm: { sta ml9+1 inx ml0: - sta asm_mul_sqr_lo,x + sta asm_mul_sqr1_lo,x bne lb1 inc ml0+2 inc ml1+2 clc iny bne lb1 + ldx #0 + ldy #$ff + !: + lda asm_mul_sqr1_hi+1,x + sta asm_mul_sqr2_hi+$100,x + lda asm_mul_sqr1_hi,x + sta asm_mul_sqr2_hi,y + lda asm_mul_sqr1_lo+1,x + sta asm_mul_sqr2_lo+$100,x + lda asm_mul_sqr1_lo,x + sta asm_mul_sqr2_lo,y + dey + inx + bne !- + lda asm_mul_sqr1_lo + sta mem + lda asm_mul_sqr1_hi + sta mem + lda asm_mul_sqr2_lo + sta mem + lda asm_mul_sqr2_hi + sta mem rts } init_mul_tables: { - .label sqr_hi = 4 - .label sqr = 7 - .label sqr_lo = 2 - .label x_2 = 6 + .label sqr1_hi = 4 + .label sqr = 6 + .label sqr1_lo = 2 + .label x_2 = $a + .label sqr2_hi = 4 + .label sqr2_lo = 2 + .label dir = $a lda #0 sta x_2 - lda #mul_sqr_hi+1 - sta sqr_hi+1 - lda #mul_sqr_lo+1 - sta sqr_lo+1 + lda #mul_sqr1_hi+1 + sta sqr1_hi+1 + lda #mul_sqr1_lo+1 + sta sqr1_lo+1 lda #0 sta sqr sta sqr+1 @@ -107,12 +252,12 @@ init_mul_tables: { b2: lda sqr ldy #0 - sta (sqr_lo),y + sta (sqr1_lo),y lda sqr+1 - sta (sqr_hi),y - inc sqr_hi + sta (sqr1_hi),y + inc sqr1_hi bne !+ - inc sqr_hi+1 + inc sqr1_hi+1 !: lda x_2 clc @@ -121,15 +266,59 @@ init_mul_tables: { bcc !+ inc sqr+1 !: - inc sqr_lo + inc sqr1_lo bne !+ - inc sqr_lo+1 + inc sqr1_lo+1 !: - lda sqr_lo+1 - cmp #>mul_sqr_lo+$200 + lda sqr1_lo+1 + cmp #>mul_sqr1_lo+$200 bne b1 - lda sqr_lo - cmp #mul_sqr2_hi + sta sqr2_hi+1 + lda #mul_sqr2_lo + sta sqr2_lo+1 + ldx #-1 + b3: + lda mul_sqr1_lo,x + ldy #0 + sta (sqr2_lo),y + lda mul_sqr1_hi,x + sta (sqr2_hi),y + inc sqr2_hi + bne !+ + inc sqr2_hi+1 + !: + txa + clc + adc dir + tax + cpx #0 + bne b4 + lda #1 + sta dir + b4: + inc sqr2_lo + bne !+ + inc sqr2_lo+1 + !: + lda sqr2_lo+1 + cmp #>mul_sqr2_lo+$1ff + bne b3 + lda sqr2_lo + cmp # (word) print_word::w#2 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#0 char_cursor#19 ] main:2::mul_tables_compare:9::print_word:23 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ) + [31] call print_byte param-assignment [ char_cursor#10 print_word::w#2 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_word::w#2 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 print_word::w#2 ] ) + to:print_word::@1 +print_word::@1: scope:[print_word] from print_word + [32] (byte) print_byte::b#1 ← < (word) print_word::w#2 [ char_cursor#10 print_byte::b#1 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::b#1 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 print_byte::b#1 ] ) + [33] call print_byte param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 ] ) + to:print_word::@return +print_word::@return: scope:[print_word] from print_word::@1 + [34] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 ] ) + to:@return +print_byte: scope:[print_byte] from print_word print_word::@1 + [35] (byte*) char_cursor#39 ← phi( print_word/(byte*) char_cursor#19 print_word::@1/(byte*) char_cursor#10 ) [ print_byte::b#2 char_cursor#39 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 ] ) + [35] (byte) print_byte::b#2 ← phi( print_word/(byte) print_byte::b#0 print_word::@1/(byte) print_byte::b#1 ) [ print_byte::b#2 char_cursor#39 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 ] ) + [36] (byte~) print_byte::$0 ← (byte) print_byte::b#2 >> (byte/signed byte/word/signed word) 4 [ print_byte::b#2 char_cursor#39 print_byte::$0 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 print_byte::$0 ] ) + [37] (byte) print_char::ch#0 ← *((const byte[]) print_byte::hextab#0 + (byte~) print_byte::$0) [ print_byte::b#2 char_cursor#39 print_char::ch#0 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 print_char::ch#0 ] ) + [38] call print_char param-assignment [ char_cursor#10 print_byte::b#2 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_byte::b#2 ] ) + to:print_byte::@1 +print_byte::@1: scope:[print_byte] from print_byte + [39] (byte~) print_byte::$2 ← (byte) print_byte::b#2 & (byte/signed byte/word/signed word) 15 [ char_cursor#10 print_byte::$2 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_byte::$2 ] ) + [40] (byte) print_char::ch#1 ← *((const byte[]) print_byte::hextab#0 + (byte~) print_byte::$2) [ char_cursor#10 print_char::ch#1 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_char::ch#1 ] ) + [41] call print_char param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 ] ) + to:print_byte::@return +print_byte::@return: scope:[print_byte] from print_byte::@1 + [42] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 ] ) + to:@return +print_char: scope:[print_char] from print_byte print_byte::@1 + [43] (byte*) char_cursor#27 ← phi( print_byte/(byte*) char_cursor#39 print_byte::@1/(byte*) char_cursor#10 ) [ print_char::ch#2 char_cursor#27 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ print_char::ch#2 char_cursor#27 ] ) + [43] (byte) print_char::ch#2 ← phi( print_byte/(byte) print_char::ch#0 print_byte::@1/(byte) print_char::ch#1 ) [ print_char::ch#2 char_cursor#27 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ print_char::ch#2 char_cursor#27 ] ) + [44] *((byte*) char_cursor#27) ← (byte) print_char::ch#2 [ char_cursor#27 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#27 ] ) + [45] (byte*) char_cursor#10 ← ++ (byte*) char_cursor#27 [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#10 ] ) + to:print_char::@return +print_char::@return: scope:[print_char] from print_char + [46] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#10 ] ) + to:@return +print_str: scope:[print_str] from mul_tables_compare::@6 mul_tables_compare::@8 + [47] (byte*) char_cursor#44 ← phi( mul_tables_compare::@6/((byte*))(word/signed word) 1024 mul_tables_compare::@8/(byte*) char_cursor#10 ) [ print_str::str#5 char_cursor#44 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#5 char_cursor#44 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#5 char_cursor#44 ] ) + [47] (byte*) print_str::str#5 ← phi( mul_tables_compare::@6/(const string) mul_tables_compare::str mul_tables_compare::@8/(const string) mul_tables_compare::str1 ) [ print_str::str#5 char_cursor#44 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#5 char_cursor#44 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#5 char_cursor#44 ] ) + to:print_str::@1 +print_str::@1: scope:[print_str] from print_str print_str::@2 + [48] (byte*) char_cursor#19 ← phi( print_str/(byte*) char_cursor#44 print_str::@2/(byte*) char_cursor#1 ) [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) + [48] (byte*) print_str::str#3 ← phi( print_str/(byte*) print_str::str#5 print_str::@2/(byte*) print_str::str#0 ) [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) + [49] if(*((byte*) print_str::str#3)!=(byte) '@') goto print_str::@2 [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) + to:print_str::@return +print_str::@return: scope:[print_str] from print_str::@1 + [50] return [ char_cursor#19 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 ] ) + to:@return +print_str::@2: scope:[print_str] from print_str::@1 + [51] *((byte*) char_cursor#19) ← *((byte*) print_str::str#3) [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) + [52] (byte*) char_cursor#1 ← ++ (byte*) char_cursor#19 [ print_str::str#3 char_cursor#1 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#3 char_cursor#1 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#3 char_cursor#1 ] ) + [53] (byte*) print_str::str#0 ← ++ (byte*) print_str::str#3 [ print_str::str#0 char_cursor#1 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#0 char_cursor#1 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#0 char_cursor#1 ] ) + to:print_str::@1 +print_cls: scope:[print_cls] from mul_tables_compare::@3 + [54] phi() [ ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) + to:print_cls::@1 +print_cls::@1: scope:[print_cls] from print_cls print_cls::@1 + [55] (byte*) print_cls::sc#2 ← phi( print_cls/((byte*))(word/signed word) 1024 print_cls::@1/(byte*) print_cls::sc#1 ) [ print_cls::sc#2 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#2 ] ) + [56] *((byte*) print_cls::sc#2) ← (byte) ' ' [ print_cls::sc#2 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#2 ] ) + [57] (byte*) print_cls::sc#1 ← ++ (byte*) print_cls::sc#2 [ print_cls::sc#1 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#1 ] ) + [58] if((byte*) print_cls::sc#1!=(word/signed word) 1024+(word/signed word) 1000) goto print_cls::@1 [ print_cls::sc#1 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#1 ] ) + to:print_cls::@return +print_cls::@return: scope:[print_cls] from print_cls::@1 + [59] return [ ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) to:@return init_mul_tables_asm: scope:[init_mul_tables_asm] from main::@1 - asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr_lo,xbnelb1incml0+2incml1+2clcinybnelb1 } + asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr1_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr1_lo,xbnelb1incml0+2incml1+2clcinybnelb1ldx#$00ldy#$ff!:ldaasm_mul_sqr1_hi+1,xstaasm_mul_sqr2_hi+$100,xldaasm_mul_sqr1_hi,xstaasm_mul_sqr2_hi,yldaasm_mul_sqr1_lo+1,xstaasm_mul_sqr2_lo+$100,xldaasm_mul_sqr1_lo,xstaasm_mul_sqr2_lo,ydeyinxbne!- } + [61] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) + [62] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) + [63] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) + [64] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) to:init_mul_tables_asm::@return init_mul_tables_asm::@return: scope:[init_mul_tables_asm] from init_mul_tables_asm - [25] return [ ] ( main:2::init_mul_tables_asm:7 [ ] ) + [65] return [ ] ( main:2::init_mul_tables_asm:7 [ ] ) to:@return init_mul_tables: scope:[init_mul_tables] from main - [26] phi() [ ] ( main:2::init_mul_tables:5 [ ] ) + [66] phi() [ ] ( main:2::init_mul_tables:5 [ ] ) to:init_mul_tables::@1 init_mul_tables::@1: scope:[init_mul_tables] from init_mul_tables init_mul_tables::@2 - [27] (byte) init_mul_tables::x_2#3 ← phi( init_mul_tables/(byte/signed byte/word/signed word) 0 init_mul_tables::@2/(byte) init_mul_tables::x_2#2 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ) - [27] (byte*) init_mul_tables::sqr_hi#2 ← phi( init_mul_tables/(const byte[512]) mul_sqr_hi#0+(byte/signed byte/word/signed word) 1 init_mul_tables::@2/(byte*) init_mul_tables::sqr_hi#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ) - [27] (byte*) init_mul_tables::sqr_lo#2 ← phi( init_mul_tables/(const byte[512]) mul_sqr_lo#0+(byte/signed byte/word/signed word) 1 init_mul_tables::@2/(byte*) init_mul_tables::sqr_lo#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ) - [27] (word) init_mul_tables::sqr#4 ← phi( init_mul_tables/(byte/signed byte/word/signed word) 0 init_mul_tables::@2/(word) init_mul_tables::sqr#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ) - [27] (byte) init_mul_tables::c#2 ← phi( init_mul_tables/(byte/signed byte/word/signed word) 0 init_mul_tables::@2/(byte) init_mul_tables::c#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ) - [28] (byte) init_mul_tables::c#1 ← ++ (byte) init_mul_tables::c#2 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) - [29] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) - [30] if((byte~) init_mul_tables::$2!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@2 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) - to:init_mul_tables::@3 -init_mul_tables::@3: scope:[init_mul_tables] from init_mul_tables::@1 - [31] (byte) init_mul_tables::x_2#1 ← ++ (byte) init_mul_tables::x_2#3 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ) - [32] (word) init_mul_tables::sqr#2 ← ++ (word) init_mul_tables::sqr#4 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ) + [67] (byte) init_mul_tables::x_2#3 ← phi( init_mul_tables/(byte/signed byte/word/signed word) 0 init_mul_tables::@2/(byte) init_mul_tables::x_2#2 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ) + [67] (byte*) init_mul_tables::sqr1_hi#2 ← phi( init_mul_tables/(const byte[512]) mul_sqr1_hi#0+(byte/signed byte/word/signed word) 1 init_mul_tables::@2/(byte*) init_mul_tables::sqr1_hi#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ) + [67] (byte*) init_mul_tables::sqr1_lo#2 ← phi( init_mul_tables/(const byte[512]) mul_sqr1_lo#0+(byte/signed byte/word/signed word) 1 init_mul_tables::@2/(byte*) init_mul_tables::sqr1_lo#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ) + [67] (word) init_mul_tables::sqr#4 ← phi( init_mul_tables/(byte/signed byte/word/signed word) 0 init_mul_tables::@2/(word) init_mul_tables::sqr#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ) + [67] (byte) init_mul_tables::c#2 ← phi( init_mul_tables/(byte/signed byte/word/signed word) 0 init_mul_tables::@2/(byte) init_mul_tables::c#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ) + [68] (byte) init_mul_tables::c#1 ← ++ (byte) init_mul_tables::c#2 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) + [69] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) + [70] if((byte~) init_mul_tables::$2!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@2 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) + to:init_mul_tables::@5 +init_mul_tables::@5: scope:[init_mul_tables] from init_mul_tables::@1 + [71] (byte) init_mul_tables::x_2#1 ← ++ (byte) init_mul_tables::x_2#3 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ) + [72] (word) init_mul_tables::sqr#2 ← ++ (word) init_mul_tables::sqr#4 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ) to:init_mul_tables::@2 -init_mul_tables::@2: scope:[init_mul_tables] from init_mul_tables::@1 init_mul_tables::@3 - [33] (byte) init_mul_tables::x_2#2 ← phi( init_mul_tables::@1/(byte) init_mul_tables::x_2#3 init_mul_tables::@3/(byte) init_mul_tables::x_2#1 ) [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) - [33] (word) init_mul_tables::sqr#3 ← phi( init_mul_tables::@1/(word) init_mul_tables::sqr#4 init_mul_tables::@3/(word) init_mul_tables::sqr#2 ) [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) - [34] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) - [35] *((byte*) init_mul_tables::sqr_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) - [36] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) - [37] *((byte*) init_mul_tables::sqr_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) - [38] (byte*) init_mul_tables::sqr_hi#1 ← ++ (byte*) init_mul_tables::sqr_hi#2 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) - [39] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) - [40] (byte*) init_mul_tables::sqr_lo#1 ← ++ (byte*) init_mul_tables::sqr_lo#2 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) - [41] if((byte*) init_mul_tables::sqr_lo#1!=(const byte[512]) mul_sqr_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) +init_mul_tables::@2: scope:[init_mul_tables] from init_mul_tables::@1 init_mul_tables::@5 + [73] (byte) init_mul_tables::x_2#2 ← phi( init_mul_tables::@1/(byte) init_mul_tables::x_2#3 init_mul_tables::@5/(byte) init_mul_tables::x_2#1 ) [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) + [73] (word) init_mul_tables::sqr#3 ← phi( init_mul_tables::@1/(word) init_mul_tables::sqr#4 init_mul_tables::@5/(word) init_mul_tables::sqr#2 ) [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) + [74] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) + [75] *((byte*) init_mul_tables::sqr1_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) + [76] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) + [77] *((byte*) init_mul_tables::sqr1_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) + [78] (byte*) init_mul_tables::sqr1_hi#1 ← ++ (byte*) init_mul_tables::sqr1_hi#2 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) + [79] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) + [80] (byte*) init_mul_tables::sqr1_lo#1 ← ++ (byte*) init_mul_tables::sqr1_lo#2 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) + [81] if((byte*) init_mul_tables::sqr1_lo#1!=(const byte[512]) mul_sqr1_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) + to:init_mul_tables::@3 +init_mul_tables::@3: scope:[init_mul_tables] from init_mul_tables::@2 init_mul_tables::@4 + [82] (byte) init_mul_tables::dir#2 ← phi( init_mul_tables::@4/(byte) init_mul_tables::dir#3 init_mul_tables::@2/(byte/word/signed word) 255 ) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) + [82] (byte*) init_mul_tables::sqr2_hi#2 ← phi( init_mul_tables::@4/(byte*) init_mul_tables::sqr2_hi#1 init_mul_tables::@2/(const byte[512]) mul_sqr2_hi#0 ) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) + [82] (byte*) init_mul_tables::sqr2_lo#2 ← phi( init_mul_tables::@4/(byte*) init_mul_tables::sqr2_lo#1 init_mul_tables::@2/(const byte[512]) mul_sqr2_lo#0 ) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) + [82] (byte) init_mul_tables::x_255#2 ← phi( init_mul_tables::@4/(byte) init_mul_tables::x_255#1 init_mul_tables::@2/((byte))-(byte/signed byte/word/signed word) 1 ) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) + [83] *((byte*) init_mul_tables::sqr2_lo#2) ← *((const byte[512]) mul_sqr1_lo#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) + [84] *((byte*) init_mul_tables::sqr2_hi#2) ← *((const byte[512]) mul_sqr1_hi#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) + [85] (byte*) init_mul_tables::sqr2_hi#1 ← ++ (byte*) init_mul_tables::sqr2_hi#2 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::sqr2_hi#1 ] ) + [86] (byte) init_mul_tables::x_255#1 ← (byte) init_mul_tables::x_255#2 + (byte) init_mul_tables::dir#2 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) + [87] if((byte) init_mul_tables::x_255#1!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@12 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) + to:init_mul_tables::@4 +init_mul_tables::@4: scope:[init_mul_tables] from init_mul_tables::@12 init_mul_tables::@3 + [88] (byte) init_mul_tables::dir#3 ← phi( init_mul_tables::@12/(byte) init_mul_tables::dir#2 init_mul_tables::@3/(byte/signed byte/word/signed word) 1 ) [ init_mul_tables::sqr2_lo#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) + [89] (byte*) init_mul_tables::sqr2_lo#1 ← ++ (byte*) init_mul_tables::sqr2_lo#2 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) + [90] if((byte*) init_mul_tables::sqr2_lo#1!=(const byte[512]) mul_sqr2_lo#0+(word/signed word) 511) goto init_mul_tables::@3 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) + to:init_mul_tables::@8 +init_mul_tables::@8: scope:[init_mul_tables] from init_mul_tables::@4 + [91] *((const byte[512]) mul_sqr2_lo#0+(word/signed word) 511) ← *((const byte[512]) mul_sqr1_lo#0+(word/signed word) 256) [ ] ( main:2::init_mul_tables:5 [ ] ) + [92] *((const byte[512]) mul_sqr2_hi#0+(word/signed word) 511) ← *((const byte[512]) mul_sqr1_hi#0+(word/signed word) 256) [ ] ( main:2::init_mul_tables:5 [ ] ) to:init_mul_tables::@return -init_mul_tables::@return: scope:[init_mul_tables] from init_mul_tables::@2 - [42] return [ ] ( main:2::init_mul_tables:5 [ ] ) +init_mul_tables::@return: scope:[init_mul_tables] from init_mul_tables::@8 + [93] return [ ] ( main:2::init_mul_tables:5 [ ] ) to:@return +init_mul_tables::@12: scope:[init_mul_tables] from init_mul_tables::@3 + [94] phi() [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) + to:init_mul_tables::@4 diff --git a/src/test/java/dk/camelot64/kickc/test/ref/multiply.log b/src/test/java/dk/camelot64/kickc/test/ref/multiply.log index f8744b49f..5592baa4c 100644 --- a/src/test/java/dk/camelot64/kickc/test/ref/multiply.log +++ b/src/test/java/dk/camelot64/kickc/test/ref/multiply.log @@ -3,6 +3,8 @@ PARSING src/test/java/dk/camelot64/kickc/test/multiply.kc // See http://codebase64.org/doku.php?id=base:seriously_fast_multiplication // Utilizes the fact that a*b = ((a+b)/2)^2 - ((a-b)/2)^2 +import "print.kc" + byte* BGCOL = $d021; void main() { @@ -11,32 +13,59 @@ void main() { mul_tables_compare(); } -// mul_sqr tables will contain f(x)=int(x*x/4). -byte[512] mul_sqr_lo; -byte[512] mul_sqr_hi; +// mul_sqr tables will contain f(x)=int(x*x/4) and g(x) = f(x-255). +// f(x) = >(( x * x )/4) +byte[512] mul_sqr1_hi; +// g(x) = >((( x - 255) * ( x - 255 ))/4) +byte[512] mul_sqr2_hi; // Initialize the mul_sqr multiplication tables with f(x)=int(x*x/4) void init_mul_tables() { - // If f(x) = x*x/4 then f(x+1) = f(x) + x/2 + 1/4 + // Fill mul_sqr1 = f(x) = int(x*x/4): If f(x) = x*x/4 then f(x+1) = f(x) + x/2 + 1/4 word sqr = 0; // sqr = (x*x)/4 byte x_2 = 0; // x/2 byte c = 0; // Counter used for determining x%2==0 - byte* sqr_hi = mul_sqr_hi+1; - for(byte* sqr_lo = mul_sqr_lo+1; sqr_lo!=mul_sqr_lo+512; sqr_lo++) { + byte* sqr1_hi = mul_sqr1_hi+1; + for(byte* sqr1_lo = mul_sqr1_lo+1; sqr1_lo!=mul_sqr1_lo+512; sqr1_lo++) { if((++c&1)==0) { x_2++; // increase i/2 on even numbers sqr++; // sqr++ on even numbers because 1 = 2*1/4 (from the two previous numbers) + 1/2 (half of the previous uneven number) } - *sqr_lo = sqr; + *sqr1_lo = sqr; sqr = sqr + x_2; // sqr = sqr + i/2 (when uneven the 1/2 is not added here - see above) } - + // Fill mul_sqr2 = g(x) = f(x-255) : If x-255<0 then g(x)=f(255-x) (because x*x = -x*-x) + // g(0) = f(255), g(1) = f(254), ..., g(254) = f(1), g(255) = f(0), g(256) = f(1), ..., g(510) = f(255), g(511) = f(256) + byte x_255 = (byte)-1; //Start with g(0)=f(255) + byte dir = $ff; // Decrease or increase x_255 - initially we decrease + byte* sqr2_hi = mul_sqr2_hi; + for(byte* sqr2_lo = mul_sqr2_lo; sqr2_lo!=mul_sqr2_lo+511; sqr2_lo++) { + *sqr2_lo = mul_sqr1_lo[x_255]; + *sqr2_hi++ = mul_sqr1_hi[x_255]; + x_255 = x_255 + dir; + if(x_255==0) { + dir = 1; // when x_255=0 then start counting up + } + } + // Set the very last value g(511) = f(256) + *(mul_sqr2_lo+511) = *(mul_sqr1_lo+256); + *(mul_sqr2_hi+511) = *(mul_sqr1_hi+256); } // ASM based multiplication tables -byte[512] asm_mul_sqr_lo; -byte[512] asm_mul_sqr_hi; +// <(( x * x )/4) +byte[512] asm_mul_sqr1_lo; +// >(( x * x )/4) +byte[512] asm_mul_sqr1_hi; +// <((( x - 255) * ( x - 255 ))/4) +byte[512] asm_mul_sqr2_lo; +// >((( x - 255) * ( x - 255 ))/4) +byte[512] asm_mul_sqr2_hi; // Initialize the multiplication tables using ASM code from // http://codebase64.org/doku.php?id=base:seriously_fast_multiplication void init_mul_tables_asm() { @@ -48,7 +77,7 @@ void init_mul_tables_asm() { tya adc #$00 ml1: - sta asm_mul_sqr_hi,x + sta asm_mul_sqr1_hi,x tay cmp #$40 txa @@ -58,38 +87,179 @@ void init_mul_tables_asm() { sta ml9+1 inx ml0: - sta asm_mul_sqr_lo,x + sta asm_mul_sqr1_lo,x bne lb1 inc ml0+2 inc ml1+2 clc iny bne lb1 + ldx #$00 + ldy #$ff + !: + lda asm_mul_sqr1_hi+1,x + sta asm_mul_sqr2_hi+$100,x + lda asm_mul_sqr1_hi,x + sta asm_mul_sqr2_hi,y + lda asm_mul_sqr1_lo+1,x + sta asm_mul_sqr2_lo+$100,x + lda asm_mul_sqr1_lo,x + sta asm_mul_sqr2_lo,y + dey + inx + bne !- } + // Ensure the ASM tables are not detected as unused by the optimizer + byte* mem = $ff; + *mem = *asm_mul_sqr1_lo; + *mem = *asm_mul_sqr1_hi; + *mem = *asm_mul_sqr2_lo; + *mem = *asm_mul_sqr2_hi; + } // Compare the ASM-based mul tables with the KC-based mul tables // Red screen on failure - green on success void mul_tables_compare() { - *BGCOL = 5; - for( byte i: 0..255) { - if(mul_sqr_lo[i] != asm_mul_sqr_lo[i]) - *BGCOL = 2; - if((mul_sqr_hi+$100)[i] != (asm_mul_sqr_hi+$100)[i]) - *BGCOL = 2; - if(mul_sqr_lo[i] != asm_mul_sqr_lo[i]) - *BGCOL = 2; - if((mul_sqr_hi+$100)[i] != (asm_mul_sqr_hi+$100)[i]) + *BGCOL = 5; + byte* asm_sqr = asm_mul_sqr1_lo; + for( byte* kc_sqr=mul_sqr1_lo; kc_sqrw); + print_byte(>4]); + print_char(hextab[b&$f]); +} + +// Print a single char +void print_char(byte ch) { + *(char_cursor++) = ch; +} + +// Clear the screen +void print_cls() { + for(byte* sc=$0400; sc!=$0400+1000; sc++) { + *sc = ' '; + } +} + + + +Adding pre/post-modifier (byte*) char_cursor ← ++ (byte*) char_cursor +Adding pre/post-modifier (byte*) print_str::str ← ++ (byte*) print_str::str +Adding pre/post-modifier (byte*) char_cursor ← ++ (byte*) char_cursor +Adding pre/post-modifier (byte*) print_cls::sc ← ++ (byte*) print_cls::sc Adding pre/post-modifier (byte) init_mul_tables::c ← ++ (byte) init_mul_tables::c Adding pre/post-modifier (byte) init_mul_tables::x_2 ← ++ (byte) init_mul_tables::x_2 Adding pre/post-modifier (word) init_mul_tables::sqr ← ++ (word) init_mul_tables::sqr -Adding pre/post-modifier (byte*) init_mul_tables::sqr_hi ← ++ (byte*) init_mul_tables::sqr_hi -Adding pre/post-modifier (byte*) init_mul_tables::sqr_lo ← ++ (byte*) init_mul_tables::sqr_lo +Adding pre/post-modifier (byte*) init_mul_tables::sqr1_hi ← ++ (byte*) init_mul_tables::sqr1_hi +Adding pre/post-modifier (byte*) init_mul_tables::sqr1_lo ← ++ (byte*) init_mul_tables::sqr1_lo +Adding pre/post-modifier (byte*) init_mul_tables::sqr2_hi ← ++ (byte*) init_mul_tables::sqr2_hi +Adding pre/post-modifier (byte*) init_mul_tables::sqr2_lo ← ++ (byte*) init_mul_tables::sqr2_lo +Adding pre/post-modifier (byte*) mul_tables_compare::asm_sqr ← ++ (byte*) mul_tables_compare::asm_sqr +Adding pre/post-modifier (byte*) mul_tables_compare::kc_sqr ← ++ (byte*) mul_tables_compare::kc_sqr STATEMENTS + (byte*) line_cursor ← (word/signed word) 1024 + (byte*) char_cursor ← (byte*) line_cursor +proc (void()) print_str((byte*) print_str::str) +print_str::@1: + (boolean~) print_str::$0 ← *((byte*) print_str::str) != (byte) '@' + if((boolean~) print_str::$0) goto print_str::@2 + goto print_str::@3 +print_str::@2: + *((byte*) char_cursor) ← *((byte*) print_str::str) + (byte*) char_cursor ← ++ (byte*) char_cursor + (byte*) print_str::str ← ++ (byte*) print_str::str + goto print_str::@1 +print_str::@3: +print_str::@return: + return +endproc // print_str() +proc (void()) print_ln() +print_ln::@1: + (byte*~) print_ln::$0 ← (byte*) line_cursor + (byte/signed byte/word/signed word) 40 + (byte*) line_cursor ← (byte*~) print_ln::$0 + (boolean~) print_ln::$1 ← (byte*) line_cursor < (byte*) char_cursor + if((boolean~) print_ln::$1) goto print_ln::@1 + (byte*) char_cursor ← (byte*) line_cursor +print_ln::@return: + return +endproc // print_ln() +proc (void()) print_word((word) print_word::w) + (byte~) print_word::$0 ← > (word) print_word::w + (void~) print_word::$1 ← call print_byte (byte~) print_word::$0 + (byte~) print_word::$2 ← < (word) print_word::w + (void~) print_word::$3 ← call print_byte (byte~) print_word::$2 +print_word::@return: + return +endproc // print_word() +proc (void()) print_byte((byte) print_byte::b) + (byte[]) print_byte::hextab ← { (byte) '0', (byte) '1', (byte) '2', (byte) '3', (byte) '4', (byte) '5', (byte) '6', (byte) '7', (byte) '8', (byte) '9', (byte) 'a', (byte) 'b', (byte) 'c', (byte) 'd', (byte) 'e', (byte) 'f' } + (byte~) print_byte::$0 ← (byte) print_byte::b >> (byte/signed byte/word/signed word) 4 + (void~) print_byte::$1 ← call print_char *((byte[]) print_byte::hextab + (byte~) print_byte::$0) + (byte~) print_byte::$2 ← (byte) print_byte::b & (byte/signed byte/word/signed word) 15 + (void~) print_byte::$3 ← call print_char *((byte[]) print_byte::hextab + (byte~) print_byte::$2) +print_byte::@return: + return +endproc // print_byte() +proc (void()) print_char((byte) print_char::ch) + *((byte*) char_cursor) ← (byte) print_char::ch + (byte*) char_cursor ← ++ (byte*) char_cursor +print_char::@return: + return +endproc // print_char() +proc (void()) print_cls() + (byte*) print_cls::sc ← (word/signed word) 1024 +print_cls::@1: + *((byte*) print_cls::sc) ← (byte) ' ' + (byte*) print_cls::sc ← ++ (byte*) print_cls::sc + (word/signed word~) print_cls::$0 ← (word/signed word) 1024 + (word/signed word) 1000 + (boolean~) print_cls::$1 ← (byte*) print_cls::sc != (word/signed word~) print_cls::$0 + if((boolean~) print_cls::$1) goto print_cls::@1 +print_cls::@return: + return +endproc // print_cls() (byte*) BGCOL ← (word) 53281 proc (void()) main() (void~) main::$0 ← call init_mul_tables @@ -98,16 +268,18 @@ proc (void()) main() main::@return: return endproc // main() - (byte[512]) mul_sqr_lo ← { fill( 512, 0) } - (byte[512]) mul_sqr_hi ← { fill( 512, 0) } + (byte[512]) mul_sqr1_lo ← { fill( 512, 0) } + (byte[512]) mul_sqr1_hi ← { fill( 512, 0) } + (byte[512]) mul_sqr2_lo ← { fill( 512, 0) } + (byte[512]) mul_sqr2_hi ← { fill( 512, 0) } proc (void()) init_mul_tables() (word) init_mul_tables::sqr ← (byte/signed byte/word/signed word) 0 (byte) init_mul_tables::x_2 ← (byte/signed byte/word/signed word) 0 (byte) init_mul_tables::c ← (byte/signed byte/word/signed word) 0 - (byte*~) init_mul_tables::$0 ← (byte[512]) mul_sqr_hi + (byte/signed byte/word/signed word) 1 - (byte*) init_mul_tables::sqr_hi ← (byte*~) init_mul_tables::$0 - (byte*~) init_mul_tables::$1 ← (byte[512]) mul_sqr_lo + (byte/signed byte/word/signed word) 1 - (byte*) init_mul_tables::sqr_lo ← (byte*~) init_mul_tables::$1 + (byte*~) init_mul_tables::$0 ← (byte[512]) mul_sqr1_hi + (byte/signed byte/word/signed word) 1 + (byte*) init_mul_tables::sqr1_hi ← (byte*~) init_mul_tables::$0 + (byte*~) init_mul_tables::$1 ← (byte[512]) mul_sqr1_lo + (byte/signed byte/word/signed word) 1 + (byte*) init_mul_tables::sqr1_lo ← (byte*~) init_mul_tables::$1 init_mul_tables::@1: (byte) init_mul_tables::c ← ++ (byte) init_mul_tables::c (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c & (byte/signed byte/word/signed word) 1 @@ -118,57 +290,84 @@ init_mul_tables::@1: (word) init_mul_tables::sqr ← ++ (word) init_mul_tables::sqr init_mul_tables::@2: (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr - *((byte*) init_mul_tables::sqr_lo) ← (byte~) init_mul_tables::$5 + *((byte*) init_mul_tables::sqr1_lo) ← (byte~) init_mul_tables::$5 (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr - *((byte*) init_mul_tables::sqr_hi) ← (byte~) init_mul_tables::$6 - (byte*) init_mul_tables::sqr_hi ← ++ (byte*) init_mul_tables::sqr_hi + *((byte*) init_mul_tables::sqr1_hi) ← (byte~) init_mul_tables::$6 + (byte*) init_mul_tables::sqr1_hi ← ++ (byte*) init_mul_tables::sqr1_hi (word~) init_mul_tables::$7 ← (word) init_mul_tables::sqr + (byte) init_mul_tables::x_2 (word) init_mul_tables::sqr ← (word~) init_mul_tables::$7 - (byte*) init_mul_tables::sqr_lo ← ++ (byte*) init_mul_tables::sqr_lo - (byte*~) init_mul_tables::$8 ← (byte[512]) mul_sqr_lo + (word/signed word) 512 - (boolean~) init_mul_tables::$9 ← (byte*) init_mul_tables::sqr_lo != (byte*~) init_mul_tables::$8 + (byte*) init_mul_tables::sqr1_lo ← ++ (byte*) init_mul_tables::sqr1_lo + (byte*~) init_mul_tables::$8 ← (byte[512]) mul_sqr1_lo + (word/signed word) 512 + (boolean~) init_mul_tables::$9 ← (byte*) init_mul_tables::sqr1_lo != (byte*~) init_mul_tables::$8 if((boolean~) init_mul_tables::$9) goto init_mul_tables::@1 + (signed byte/signed word~) init_mul_tables::$10 ← - (byte/signed byte/word/signed word) 1 + (byte~) init_mul_tables::$11 ← ((byte)) (signed byte/signed word~) init_mul_tables::$10 + (byte) init_mul_tables::x_255 ← (byte~) init_mul_tables::$11 + (byte) init_mul_tables::dir ← (byte/word/signed word) 255 + (byte*) init_mul_tables::sqr2_hi ← (byte[512]) mul_sqr2_hi + (byte*) init_mul_tables::sqr2_lo ← (byte[512]) mul_sqr2_lo +init_mul_tables::@3: + *((byte*) init_mul_tables::sqr2_lo) ← *((byte[512]) mul_sqr1_lo + (byte) init_mul_tables::x_255) + *((byte*) init_mul_tables::sqr2_hi) ← *((byte[512]) mul_sqr1_hi + (byte) init_mul_tables::x_255) + (byte*) init_mul_tables::sqr2_hi ← ++ (byte*) init_mul_tables::sqr2_hi + (byte/word~) init_mul_tables::$12 ← (byte) init_mul_tables::x_255 + (byte) init_mul_tables::dir + (byte) init_mul_tables::x_255 ← (byte/word~) init_mul_tables::$12 + (boolean~) init_mul_tables::$13 ← (byte) init_mul_tables::x_255 == (byte/signed byte/word/signed word) 0 + (boolean~) init_mul_tables::$14 ← ! (boolean~) init_mul_tables::$13 + if((boolean~) init_mul_tables::$14) goto init_mul_tables::@4 + (byte) init_mul_tables::dir ← (byte/signed byte/word/signed word) 1 +init_mul_tables::@4: + (byte*) init_mul_tables::sqr2_lo ← ++ (byte*) init_mul_tables::sqr2_lo + (byte*~) init_mul_tables::$15 ← (byte[512]) mul_sqr2_lo + (word/signed word) 511 + (boolean~) init_mul_tables::$16 ← (byte*) init_mul_tables::sqr2_lo != (byte*~) init_mul_tables::$15 + if((boolean~) init_mul_tables::$16) goto init_mul_tables::@3 + (byte*~) init_mul_tables::$17 ← (byte[512]) mul_sqr2_lo + (word/signed word) 511 + (byte*~) init_mul_tables::$18 ← (byte[512]) mul_sqr1_lo + (word/signed word) 256 + *((byte*~) init_mul_tables::$17) ← *((byte*~) init_mul_tables::$18) + (byte*~) init_mul_tables::$19 ← (byte[512]) mul_sqr2_hi + (word/signed word) 511 + (byte*~) init_mul_tables::$20 ← (byte[512]) mul_sqr1_hi + (word/signed word) 256 + *((byte*~) init_mul_tables::$19) ← *((byte*~) init_mul_tables::$20) init_mul_tables::@return: return endproc // init_mul_tables() - (byte[512]) asm_mul_sqr_lo ← { fill( 512, 0) } - (byte[512]) asm_mul_sqr_hi ← { fill( 512, 0) } + (byte[512]) asm_mul_sqr1_lo ← { fill( 512, 0) } + (byte[512]) asm_mul_sqr1_hi ← { fill( 512, 0) } + (byte[512]) asm_mul_sqr2_lo ← { fill( 512, 0) } + (byte[512]) asm_mul_sqr2_hi ← { fill( 512, 0) } proc (void()) init_mul_tables_asm() - asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr_lo,xbnelb1incml0+2incml1+2clcinybnelb1 } + asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr1_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr1_lo,xbnelb1incml0+2incml1+2clcinybnelb1ldx#$00ldy#$ff!:ldaasm_mul_sqr1_hi+1,xstaasm_mul_sqr2_hi+$100,xldaasm_mul_sqr1_hi,xstaasm_mul_sqr2_hi,yldaasm_mul_sqr1_lo+1,xstaasm_mul_sqr2_lo+$100,xldaasm_mul_sqr1_lo,xstaasm_mul_sqr2_lo,ydeyinxbne!- } + (byte*) init_mul_tables_asm::mem ← (byte/word/signed word) 255 + *((byte*) init_mul_tables_asm::mem) ← *((byte[512]) asm_mul_sqr1_lo) + *((byte*) init_mul_tables_asm::mem) ← *((byte[512]) asm_mul_sqr1_hi) + *((byte*) init_mul_tables_asm::mem) ← *((byte[512]) asm_mul_sqr2_lo) + *((byte*) init_mul_tables_asm::mem) ← *((byte[512]) asm_mul_sqr2_hi) init_mul_tables_asm::@return: return endproc // init_mul_tables_asm() proc (void()) mul_tables_compare() *((byte*) BGCOL) ← (byte/signed byte/word/signed word) 5 - (byte) mul_tables_compare::i ← (byte/signed byte/word/signed word) 0 + (byte*) mul_tables_compare::asm_sqr ← (byte[512]) asm_mul_sqr1_lo + (byte*) mul_tables_compare::kc_sqr ← (byte[512]) mul_sqr1_lo mul_tables_compare::@1: - (boolean~) mul_tables_compare::$0 ← *((byte[512]) mul_sqr_lo + (byte) mul_tables_compare::i) != *((byte[512]) asm_mul_sqr_lo + (byte) mul_tables_compare::i) + (boolean~) mul_tables_compare::$0 ← *((byte*) mul_tables_compare::kc_sqr) != *((byte*) mul_tables_compare::asm_sqr) (boolean~) mul_tables_compare::$1 ← ! (boolean~) mul_tables_compare::$0 if((boolean~) mul_tables_compare::$1) goto mul_tables_compare::@2 *((byte*) BGCOL) ← (byte/signed byte/word/signed word) 2 + (void~) mul_tables_compare::$2 ← call print_cls + (void~) mul_tables_compare::$3 ← call print_str (string) "mul table mismatch at @" + (word~) mul_tables_compare::$4 ← ((word)) (byte*) mul_tables_compare::asm_sqr + (void~) mul_tables_compare::$5 ← call print_word (word~) mul_tables_compare::$4 + (void~) mul_tables_compare::$6 ← call print_str (string) " / @" + (word~) mul_tables_compare::$7 ← ((word)) (byte*) mul_tables_compare::kc_sqr + (void~) mul_tables_compare::$8 ← call print_word (word~) mul_tables_compare::$7 + goto mul_tables_compare::@return mul_tables_compare::@2: - (byte*~) mul_tables_compare::$2 ← (byte[512]) mul_sqr_hi + (word/signed word) 256 - (byte*~) mul_tables_compare::$3 ← (byte[512]) asm_mul_sqr_hi + (word/signed word) 256 - (boolean~) mul_tables_compare::$4 ← *((byte*~) mul_tables_compare::$2 + (byte) mul_tables_compare::i) != *((byte*~) mul_tables_compare::$3 + (byte) mul_tables_compare::i) - (boolean~) mul_tables_compare::$5 ← ! (boolean~) mul_tables_compare::$4 - if((boolean~) mul_tables_compare::$5) goto mul_tables_compare::@3 - *((byte*) BGCOL) ← (byte/signed byte/word/signed word) 2 -mul_tables_compare::@3: - (boolean~) mul_tables_compare::$6 ← *((byte[512]) mul_sqr_lo + (byte) mul_tables_compare::i) != *((byte[512]) asm_mul_sqr_lo + (byte) mul_tables_compare::i) - (boolean~) mul_tables_compare::$7 ← ! (boolean~) mul_tables_compare::$6 - if((boolean~) mul_tables_compare::$7) goto mul_tables_compare::@4 - *((byte*) BGCOL) ← (byte/signed byte/word/signed word) 2 -mul_tables_compare::@4: - (byte*~) mul_tables_compare::$8 ← (byte[512]) mul_sqr_hi + (word/signed word) 256 - (byte*~) mul_tables_compare::$9 ← (byte[512]) asm_mul_sqr_hi + (word/signed word) 256 - (boolean~) mul_tables_compare::$10 ← *((byte*~) mul_tables_compare::$8 + (byte) mul_tables_compare::i) != *((byte*~) mul_tables_compare::$9 + (byte) mul_tables_compare::i) - (boolean~) mul_tables_compare::$11 ← ! (boolean~) mul_tables_compare::$10 - if((boolean~) mul_tables_compare::$11) goto mul_tables_compare::@5 - *((byte*) BGCOL) ← (byte/signed byte/word/signed word) 2 -mul_tables_compare::@5: - (byte) mul_tables_compare::i ← ++ (byte) mul_tables_compare::i - (boolean~) mul_tables_compare::$12 ← (byte) mul_tables_compare::i != (byte/signed byte/word/signed word) 0 - if((boolean~) mul_tables_compare::$12) goto mul_tables_compare::@1 + (byte*) mul_tables_compare::asm_sqr ← ++ (byte*) mul_tables_compare::asm_sqr + (byte*) mul_tables_compare::kc_sqr ← ++ (byte*) mul_tables_compare::kc_sqr + (word/signed word~) mul_tables_compare::$9 ← (word/signed word) 512 * (byte/signed byte/word/signed word) 4 + (byte*~) mul_tables_compare::$10 ← (byte[512]) mul_sqr1_lo + (word/signed word~) mul_tables_compare::$9 + (boolean~) mul_tables_compare::$11 ← (byte*) mul_tables_compare::kc_sqr < (byte*~) mul_tables_compare::$10 + if((boolean~) mul_tables_compare::$11) goto mul_tables_compare::@1 mul_tables_compare::@return: return endproc // mul_tables_compare() @@ -176,12 +375,26 @@ endproc // mul_tables_compare() SYMBOLS (byte*) BGCOL -(byte[512]) asm_mul_sqr_hi -(byte[512]) asm_mul_sqr_lo +(byte[512]) asm_mul_sqr1_hi +(byte[512]) asm_mul_sqr1_lo +(byte[512]) asm_mul_sqr2_hi +(byte[512]) asm_mul_sqr2_lo +(byte*) char_cursor (void()) init_mul_tables() (byte*~) init_mul_tables::$0 (byte*~) init_mul_tables::$1 +(signed byte/signed word~) init_mul_tables::$10 +(byte~) init_mul_tables::$11 +(byte/word~) init_mul_tables::$12 +(boolean~) init_mul_tables::$13 +(boolean~) init_mul_tables::$14 +(byte*~) init_mul_tables::$15 +(boolean~) init_mul_tables::$16 +(byte*~) init_mul_tables::$17 +(byte*~) init_mul_tables::$18 +(byte*~) init_mul_tables::$19 (byte~) init_mul_tables::$2 +(byte*~) init_mul_tables::$20 (boolean~) init_mul_tables::$3 (boolean~) init_mul_tables::$4 (byte~) init_mul_tables::$5 @@ -191,48 +404,185 @@ SYMBOLS (boolean~) init_mul_tables::$9 (label) init_mul_tables::@1 (label) init_mul_tables::@2 +(label) init_mul_tables::@3 +(label) init_mul_tables::@4 (label) init_mul_tables::@return (byte) init_mul_tables::c +(byte) init_mul_tables::dir (word) init_mul_tables::sqr -(byte*) init_mul_tables::sqr_hi -(byte*) init_mul_tables::sqr_lo +(byte*) init_mul_tables::sqr1_hi +(byte*) init_mul_tables::sqr1_lo +(byte*) init_mul_tables::sqr2_hi +(byte*) init_mul_tables::sqr2_lo (byte) init_mul_tables::x_2 +(byte) init_mul_tables::x_255 (void()) init_mul_tables_asm() (label) init_mul_tables_asm::@return +(byte*) init_mul_tables_asm::mem +(byte*) line_cursor (void()) main() (void~) main::$0 (void~) main::$1 (void~) main::$2 (label) main::@return -(byte[512]) mul_sqr_hi -(byte[512]) mul_sqr_lo +(byte[512]) mul_sqr1_hi +(byte[512]) mul_sqr1_lo +(byte[512]) mul_sqr2_hi +(byte[512]) mul_sqr2_lo (void()) mul_tables_compare() (boolean~) mul_tables_compare::$0 (boolean~) mul_tables_compare::$1 -(boolean~) mul_tables_compare::$10 +(byte*~) mul_tables_compare::$10 (boolean~) mul_tables_compare::$11 -(boolean~) mul_tables_compare::$12 -(byte*~) mul_tables_compare::$2 -(byte*~) mul_tables_compare::$3 -(boolean~) mul_tables_compare::$4 -(boolean~) mul_tables_compare::$5 -(boolean~) mul_tables_compare::$6 -(boolean~) mul_tables_compare::$7 -(byte*~) mul_tables_compare::$8 -(byte*~) mul_tables_compare::$9 +(void~) mul_tables_compare::$2 +(void~) mul_tables_compare::$3 +(word~) mul_tables_compare::$4 +(void~) mul_tables_compare::$5 +(void~) mul_tables_compare::$6 +(word~) mul_tables_compare::$7 +(void~) mul_tables_compare::$8 +(word/signed word~) mul_tables_compare::$9 (label) mul_tables_compare::@1 (label) mul_tables_compare::@2 -(label) mul_tables_compare::@3 -(label) mul_tables_compare::@4 -(label) mul_tables_compare::@5 (label) mul_tables_compare::@return -(byte) mul_tables_compare::i +(byte*) mul_tables_compare::asm_sqr +(byte*) mul_tables_compare::kc_sqr +(void()) print_byte((byte) print_byte::b) +(byte~) print_byte::$0 +(void~) print_byte::$1 +(byte~) print_byte::$2 +(void~) print_byte::$3 +(label) print_byte::@return +(byte) print_byte::b +(byte[]) print_byte::hextab +(void()) print_char((byte) print_char::ch) +(label) print_char::@return +(byte) print_char::ch +(void()) print_cls() +(word/signed word~) print_cls::$0 +(boolean~) print_cls::$1 +(label) print_cls::@1 +(label) print_cls::@return +(byte*) print_cls::sc +(void()) print_ln() +(byte*~) print_ln::$0 +(boolean~) print_ln::$1 +(label) print_ln::@1 +(label) print_ln::@return +(void()) print_str((byte*) print_str::str) +(boolean~) print_str::$0 +(label) print_str::@1 +(label) print_str::@2 +(label) print_str::@3 +(label) print_str::@return +(byte*) print_str::str +(void()) print_word((word) print_word::w) +(byte~) print_word::$0 +(void~) print_word::$1 +(byte~) print_word::$2 +(void~) print_word::$3 +(label) print_word::@return +(word) print_word::w +Promoting word/signed word to byte* in line_cursor ← ((byte*)) 1024 +Promoting word/signed word to byte* in print_cls::sc ← ((byte*)) 1024 Promoting word to byte* in BGCOL ← ((byte*)) 53281 +Promoting byte/word/signed word to byte* in init_mul_tables_asm::mem ← ((byte*)) 255 INITIAL CONTROL FLOW GRAPH @begin: scope:[] from - (byte*) BGCOL ← ((byte*)) (word) 53281 + (byte*) line_cursor ← ((byte*)) (word/signed word) 1024 + (byte*) char_cursor ← (byte*) line_cursor to:@1 +print_str: scope:[print_str] from + to:print_str::@1 +print_str::@1: scope:[print_str] from print_str print_str::@2 + (boolean~) print_str::$0 ← *((byte*) print_str::str) != (byte) '@' + if((boolean~) print_str::$0) goto print_str::@2 + to:print_str::@4 +print_str::@2: scope:[print_str] from print_str::@1 print_str::@5 + *((byte*) char_cursor) ← *((byte*) print_str::str) + (byte*) char_cursor ← ++ (byte*) char_cursor + (byte*) print_str::str ← ++ (byte*) print_str::str + to:print_str::@1 +print_str::@4: scope:[print_str] from print_str::@1 + to:print_str::@3 +print_str::@3: scope:[print_str] from print_str::@4 print_str::@6 + to:print_str::@return +print_str::@5: scope:[print_str] from + to:print_str::@2 +print_str::@6: scope:[print_str] from + to:print_str::@3 +print_str::@return: scope:[print_str] from print_str::@3 + return + to:@return +@1: scope:[] from @begin + to:@2 +print_ln: scope:[print_ln] from + to:print_ln::@1 +print_ln::@1: scope:[print_ln] from print_ln print_ln::@1 + (byte*~) print_ln::$0 ← (byte*) line_cursor + (byte/signed byte/word/signed word) 40 + (byte*) line_cursor ← (byte*~) print_ln::$0 + (boolean~) print_ln::$1 ← (byte*) line_cursor < (byte*) char_cursor + if((boolean~) print_ln::$1) goto print_ln::@1 + to:print_ln::@2 +print_ln::@2: scope:[print_ln] from print_ln::@1 + (byte*) char_cursor ← (byte*) line_cursor + to:print_ln::@return +print_ln::@return: scope:[print_ln] from print_ln::@2 + return + to:@return +@2: scope:[] from @1 + to:@3 +print_word: scope:[print_word] from + (byte~) print_word::$0 ← > (word) print_word::w + (void~) print_word::$1 ← call print_byte (byte~) print_word::$0 + (byte~) print_word::$2 ← < (word) print_word::w + (void~) print_word::$3 ← call print_byte (byte~) print_word::$2 + to:print_word::@return +print_word::@return: scope:[print_word] from print_word + return + to:@return +@3: scope:[] from @2 + to:@4 +print_byte: scope:[print_byte] from + (byte[]) print_byte::hextab ← { (byte) '0', (byte) '1', (byte) '2', (byte) '3', (byte) '4', (byte) '5', (byte) '6', (byte) '7', (byte) '8', (byte) '9', (byte) 'a', (byte) 'b', (byte) 'c', (byte) 'd', (byte) 'e', (byte) 'f' } + (byte~) print_byte::$0 ← (byte) print_byte::b >> (byte/signed byte/word/signed word) 4 + (void~) print_byte::$1 ← call print_char *((byte[]) print_byte::hextab + (byte~) print_byte::$0) + (byte~) print_byte::$2 ← (byte) print_byte::b & (byte/signed byte/word/signed word) 15 + (void~) print_byte::$3 ← call print_char *((byte[]) print_byte::hextab + (byte~) print_byte::$2) + to:print_byte::@return +print_byte::@return: scope:[print_byte] from print_byte + return + to:@return +@4: scope:[] from @3 + to:@5 +print_char: scope:[print_char] from + *((byte*) char_cursor) ← (byte) print_char::ch + (byte*) char_cursor ← ++ (byte*) char_cursor + to:print_char::@return +print_char::@return: scope:[print_char] from print_char + return + to:@return +@5: scope:[] from @4 + to:@6 +print_cls: scope:[print_cls] from + (byte*) print_cls::sc ← ((byte*)) (word/signed word) 1024 + to:print_cls::@1 +print_cls::@1: scope:[print_cls] from print_cls print_cls::@1 + *((byte*) print_cls::sc) ← (byte) ' ' + (byte*) print_cls::sc ← ++ (byte*) print_cls::sc + (word/signed word~) print_cls::$0 ← (word/signed word) 1024 + (word/signed word) 1000 + (boolean~) print_cls::$1 ← (byte*) print_cls::sc != (word/signed word~) print_cls::$0 + if((boolean~) print_cls::$1) goto print_cls::@1 + to:print_cls::@2 +print_cls::@2: scope:[print_cls] from print_cls::@1 + to:print_cls::@return +print_cls::@return: scope:[print_cls] from print_cls::@2 + return + to:@return +@6: scope:[] from @5 + (byte*) BGCOL ← ((byte*)) (word) 53281 + to:@7 main: scope:[main] from (void~) main::$0 ← call init_mul_tables (void~) main::$1 ← call init_mul_tables_asm @@ -241,18 +591,20 @@ main: scope:[main] from main::@return: scope:[main] from main return to:@return -@1: scope:[] from @begin - (byte[512]) mul_sqr_lo ← { fill( 512, 0) } - (byte[512]) mul_sqr_hi ← { fill( 512, 0) } - to:@2 +@7: scope:[] from @6 + (byte[512]) mul_sqr1_lo ← { fill( 512, 0) } + (byte[512]) mul_sqr1_hi ← { fill( 512, 0) } + (byte[512]) mul_sqr2_lo ← { fill( 512, 0) } + (byte[512]) mul_sqr2_hi ← { fill( 512, 0) } + to:@8 init_mul_tables: scope:[init_mul_tables] from (word) init_mul_tables::sqr ← (byte/signed byte/word/signed word) 0 (byte) init_mul_tables::x_2 ← (byte/signed byte/word/signed word) 0 (byte) init_mul_tables::c ← (byte/signed byte/word/signed word) 0 - (byte*~) init_mul_tables::$0 ← (byte[512]) mul_sqr_hi + (byte/signed byte/word/signed word) 1 - (byte*) init_mul_tables::sqr_hi ← (byte*~) init_mul_tables::$0 - (byte*~) init_mul_tables::$1 ← (byte[512]) mul_sqr_lo + (byte/signed byte/word/signed word) 1 - (byte*) init_mul_tables::sqr_lo ← (byte*~) init_mul_tables::$1 + (byte*~) init_mul_tables::$0 ← (byte[512]) mul_sqr1_hi + (byte/signed byte/word/signed word) 1 + (byte*) init_mul_tables::sqr1_hi ← (byte*~) init_mul_tables::$0 + (byte*~) init_mul_tables::$1 ← (byte[512]) mul_sqr1_lo + (byte/signed byte/word/signed word) 1 + (byte*) init_mul_tables::sqr1_lo ← (byte*~) init_mul_tables::$1 to:init_mul_tables::@1 init_mul_tables::@1: scope:[init_mul_tables] from init_mul_tables init_mul_tables::@2 (byte) init_mul_tables::c ← ++ (byte) init_mul_tables::c @@ -260,103 +612,156 @@ init_mul_tables::@1: scope:[init_mul_tables] from init_mul_tables init_mul_tabl (boolean~) init_mul_tables::$3 ← (byte~) init_mul_tables::$2 == (byte/signed byte/word/signed word) 0 (boolean~) init_mul_tables::$4 ← ! (boolean~) init_mul_tables::$3 if((boolean~) init_mul_tables::$4) goto init_mul_tables::@2 - to:init_mul_tables::@3 -init_mul_tables::@2: scope:[init_mul_tables] from init_mul_tables::@1 init_mul_tables::@3 + to:init_mul_tables::@5 +init_mul_tables::@2: scope:[init_mul_tables] from init_mul_tables::@1 init_mul_tables::@5 (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr - *((byte*) init_mul_tables::sqr_lo) ← (byte~) init_mul_tables::$5 + *((byte*) init_mul_tables::sqr1_lo) ← (byte~) init_mul_tables::$5 (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr - *((byte*) init_mul_tables::sqr_hi) ← (byte~) init_mul_tables::$6 - (byte*) init_mul_tables::sqr_hi ← ++ (byte*) init_mul_tables::sqr_hi + *((byte*) init_mul_tables::sqr1_hi) ← (byte~) init_mul_tables::$6 + (byte*) init_mul_tables::sqr1_hi ← ++ (byte*) init_mul_tables::sqr1_hi (word~) init_mul_tables::$7 ← (word) init_mul_tables::sqr + (byte) init_mul_tables::x_2 (word) init_mul_tables::sqr ← (word~) init_mul_tables::$7 - (byte*) init_mul_tables::sqr_lo ← ++ (byte*) init_mul_tables::sqr_lo - (byte*~) init_mul_tables::$8 ← (byte[512]) mul_sqr_lo + (word/signed word) 512 - (boolean~) init_mul_tables::$9 ← (byte*) init_mul_tables::sqr_lo != (byte*~) init_mul_tables::$8 + (byte*) init_mul_tables::sqr1_lo ← ++ (byte*) init_mul_tables::sqr1_lo + (byte*~) init_mul_tables::$8 ← (byte[512]) mul_sqr1_lo + (word/signed word) 512 + (boolean~) init_mul_tables::$9 ← (byte*) init_mul_tables::sqr1_lo != (byte*~) init_mul_tables::$8 if((boolean~) init_mul_tables::$9) goto init_mul_tables::@1 - to:init_mul_tables::@4 -init_mul_tables::@3: scope:[init_mul_tables] from init_mul_tables::@1 + to:init_mul_tables::@6 +init_mul_tables::@5: scope:[init_mul_tables] from init_mul_tables::@1 (byte) init_mul_tables::x_2 ← ++ (byte) init_mul_tables::x_2 (word) init_mul_tables::sqr ← ++ (word) init_mul_tables::sqr to:init_mul_tables::@2 -init_mul_tables::@4: scope:[init_mul_tables] from init_mul_tables::@2 +init_mul_tables::@6: scope:[init_mul_tables] from init_mul_tables::@2 + (signed byte/signed word~) init_mul_tables::$10 ← - (byte/signed byte/word/signed word) 1 + (byte~) init_mul_tables::$11 ← ((byte)) (signed byte/signed word~) init_mul_tables::$10 + (byte) init_mul_tables::x_255 ← (byte~) init_mul_tables::$11 + (byte) init_mul_tables::dir ← (byte/word/signed word) 255 + (byte*) init_mul_tables::sqr2_hi ← (byte[512]) mul_sqr2_hi + (byte*) init_mul_tables::sqr2_lo ← (byte[512]) mul_sqr2_lo + to:init_mul_tables::@3 +init_mul_tables::@3: scope:[init_mul_tables] from init_mul_tables::@4 init_mul_tables::@6 + *((byte*) init_mul_tables::sqr2_lo) ← *((byte[512]) mul_sqr1_lo + (byte) init_mul_tables::x_255) + *((byte*) init_mul_tables::sqr2_hi) ← *((byte[512]) mul_sqr1_hi + (byte) init_mul_tables::x_255) + (byte*) init_mul_tables::sqr2_hi ← ++ (byte*) init_mul_tables::sqr2_hi + (byte/word~) init_mul_tables::$12 ← (byte) init_mul_tables::x_255 + (byte) init_mul_tables::dir + (byte) init_mul_tables::x_255 ← (byte/word~) init_mul_tables::$12 + (boolean~) init_mul_tables::$13 ← (byte) init_mul_tables::x_255 == (byte/signed byte/word/signed word) 0 + (boolean~) init_mul_tables::$14 ← ! (boolean~) init_mul_tables::$13 + if((boolean~) init_mul_tables::$14) goto init_mul_tables::@4 + to:init_mul_tables::@7 +init_mul_tables::@4: scope:[init_mul_tables] from init_mul_tables::@3 init_mul_tables::@7 + (byte*) init_mul_tables::sqr2_lo ← ++ (byte*) init_mul_tables::sqr2_lo + (byte*~) init_mul_tables::$15 ← (byte[512]) mul_sqr2_lo + (word/signed word) 511 + (boolean~) init_mul_tables::$16 ← (byte*) init_mul_tables::sqr2_lo != (byte*~) init_mul_tables::$15 + if((boolean~) init_mul_tables::$16) goto init_mul_tables::@3 + to:init_mul_tables::@8 +init_mul_tables::@7: scope:[init_mul_tables] from init_mul_tables::@3 + (byte) init_mul_tables::dir ← (byte/signed byte/word/signed word) 1 + to:init_mul_tables::@4 +init_mul_tables::@8: scope:[init_mul_tables] from init_mul_tables::@4 + (byte*~) init_mul_tables::$17 ← (byte[512]) mul_sqr2_lo + (word/signed word) 511 + (byte*~) init_mul_tables::$18 ← (byte[512]) mul_sqr1_lo + (word/signed word) 256 + *((byte*~) init_mul_tables::$17) ← *((byte*~) init_mul_tables::$18) + (byte*~) init_mul_tables::$19 ← (byte[512]) mul_sqr2_hi + (word/signed word) 511 + (byte*~) init_mul_tables::$20 ← (byte[512]) mul_sqr1_hi + (word/signed word) 256 + *((byte*~) init_mul_tables::$19) ← *((byte*~) init_mul_tables::$20) to:init_mul_tables::@return -init_mul_tables::@return: scope:[init_mul_tables] from init_mul_tables::@4 +init_mul_tables::@return: scope:[init_mul_tables] from init_mul_tables::@8 return to:@return -@2: scope:[] from @1 - (byte[512]) asm_mul_sqr_lo ← { fill( 512, 0) } - (byte[512]) asm_mul_sqr_hi ← { fill( 512, 0) } - to:@3 +@8: scope:[] from @7 + (byte[512]) asm_mul_sqr1_lo ← { fill( 512, 0) } + (byte[512]) asm_mul_sqr1_hi ← { fill( 512, 0) } + (byte[512]) asm_mul_sqr2_lo ← { fill( 512, 0) } + (byte[512]) asm_mul_sqr2_hi ← { fill( 512, 0) } + to:@9 init_mul_tables_asm: scope:[init_mul_tables_asm] from - asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr_lo,xbnelb1incml0+2incml1+2clcinybnelb1 } + asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr1_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr1_lo,xbnelb1incml0+2incml1+2clcinybnelb1ldx#$00ldy#$ff!:ldaasm_mul_sqr1_hi+1,xstaasm_mul_sqr2_hi+$100,xldaasm_mul_sqr1_hi,xstaasm_mul_sqr2_hi,yldaasm_mul_sqr1_lo+1,xstaasm_mul_sqr2_lo+$100,xldaasm_mul_sqr1_lo,xstaasm_mul_sqr2_lo,ydeyinxbne!- } + (byte*) init_mul_tables_asm::mem ← ((byte*)) (byte/word/signed word) 255 + *((byte*) init_mul_tables_asm::mem) ← *((byte[512]) asm_mul_sqr1_lo) + *((byte*) init_mul_tables_asm::mem) ← *((byte[512]) asm_mul_sqr1_hi) + *((byte*) init_mul_tables_asm::mem) ← *((byte[512]) asm_mul_sqr2_lo) + *((byte*) init_mul_tables_asm::mem) ← *((byte[512]) asm_mul_sqr2_hi) to:init_mul_tables_asm::@return init_mul_tables_asm::@return: scope:[init_mul_tables_asm] from init_mul_tables_asm return to:@return -@3: scope:[] from @2 - to:@4 +@9: scope:[] from @8 + to:@10 mul_tables_compare: scope:[mul_tables_compare] from *((byte*) BGCOL) ← (byte/signed byte/word/signed word) 5 - (byte) mul_tables_compare::i ← (byte/signed byte/word/signed word) 0 + (byte*) mul_tables_compare::asm_sqr ← (byte[512]) asm_mul_sqr1_lo + (byte*) mul_tables_compare::kc_sqr ← (byte[512]) mul_sqr1_lo to:mul_tables_compare::@1 -mul_tables_compare::@1: scope:[mul_tables_compare] from mul_tables_compare mul_tables_compare::@5 - (boolean~) mul_tables_compare::$0 ← *((byte[512]) mul_sqr_lo + (byte) mul_tables_compare::i) != *((byte[512]) asm_mul_sqr_lo + (byte) mul_tables_compare::i) +mul_tables_compare::@1: scope:[mul_tables_compare] from mul_tables_compare mul_tables_compare::@2 + (boolean~) mul_tables_compare::$0 ← *((byte*) mul_tables_compare::kc_sqr) != *((byte*) mul_tables_compare::asm_sqr) (boolean~) mul_tables_compare::$1 ← ! (boolean~) mul_tables_compare::$0 if((boolean~) mul_tables_compare::$1) goto mul_tables_compare::@2 - to:mul_tables_compare::@6 -mul_tables_compare::@2: scope:[mul_tables_compare] from mul_tables_compare::@1 mul_tables_compare::@6 - (byte*~) mul_tables_compare::$2 ← (byte[512]) mul_sqr_hi + (word/signed word) 256 - (byte*~) mul_tables_compare::$3 ← (byte[512]) asm_mul_sqr_hi + (word/signed word) 256 - (boolean~) mul_tables_compare::$4 ← *((byte*~) mul_tables_compare::$2 + (byte) mul_tables_compare::i) != *((byte*~) mul_tables_compare::$3 + (byte) mul_tables_compare::i) - (boolean~) mul_tables_compare::$5 ← ! (boolean~) mul_tables_compare::$4 - if((boolean~) mul_tables_compare::$5) goto mul_tables_compare::@3 - to:mul_tables_compare::@7 -mul_tables_compare::@6: scope:[mul_tables_compare] from mul_tables_compare::@1 - *((byte*) BGCOL) ← (byte/signed byte/word/signed word) 2 - to:mul_tables_compare::@2 -mul_tables_compare::@3: scope:[mul_tables_compare] from mul_tables_compare::@2 mul_tables_compare::@7 - (boolean~) mul_tables_compare::$6 ← *((byte[512]) mul_sqr_lo + (byte) mul_tables_compare::i) != *((byte[512]) asm_mul_sqr_lo + (byte) mul_tables_compare::i) - (boolean~) mul_tables_compare::$7 ← ! (boolean~) mul_tables_compare::$6 - if((boolean~) mul_tables_compare::$7) goto mul_tables_compare::@4 - to:mul_tables_compare::@8 -mul_tables_compare::@7: scope:[mul_tables_compare] from mul_tables_compare::@2 - *((byte*) BGCOL) ← (byte/signed byte/word/signed word) 2 to:mul_tables_compare::@3 -mul_tables_compare::@4: scope:[mul_tables_compare] from mul_tables_compare::@3 mul_tables_compare::@8 - (byte*~) mul_tables_compare::$8 ← (byte[512]) mul_sqr_hi + (word/signed word) 256 - (byte*~) mul_tables_compare::$9 ← (byte[512]) asm_mul_sqr_hi + (word/signed word) 256 - (boolean~) mul_tables_compare::$10 ← *((byte*~) mul_tables_compare::$8 + (byte) mul_tables_compare::i) != *((byte*~) mul_tables_compare::$9 + (byte) mul_tables_compare::i) - (boolean~) mul_tables_compare::$11 ← ! (boolean~) mul_tables_compare::$10 - if((boolean~) mul_tables_compare::$11) goto mul_tables_compare::@5 - to:mul_tables_compare::@9 -mul_tables_compare::@8: scope:[mul_tables_compare] from mul_tables_compare::@3 - *((byte*) BGCOL) ← (byte/signed byte/word/signed word) 2 - to:mul_tables_compare::@4 -mul_tables_compare::@5: scope:[mul_tables_compare] from mul_tables_compare::@4 mul_tables_compare::@9 - (byte) mul_tables_compare::i ← ++ (byte) mul_tables_compare::i - (boolean~) mul_tables_compare::$12 ← (byte) mul_tables_compare::i != (byte/signed byte/word/signed word) 0 - if((boolean~) mul_tables_compare::$12) goto mul_tables_compare::@1 - to:mul_tables_compare::@10 -mul_tables_compare::@9: scope:[mul_tables_compare] from mul_tables_compare::@4 - *((byte*) BGCOL) ← (byte/signed byte/word/signed word) 2 +mul_tables_compare::@2: scope:[mul_tables_compare] from mul_tables_compare::@1 mul_tables_compare::@4 + (byte*) mul_tables_compare::asm_sqr ← ++ (byte*) mul_tables_compare::asm_sqr + (byte*) mul_tables_compare::kc_sqr ← ++ (byte*) mul_tables_compare::kc_sqr + (word/signed word~) mul_tables_compare::$9 ← (word/signed word) 512 * (byte/signed byte/word/signed word) 4 + (byte*~) mul_tables_compare::$10 ← (byte[512]) mul_sqr1_lo + (word/signed word~) mul_tables_compare::$9 + (boolean~) mul_tables_compare::$11 ← (byte*) mul_tables_compare::kc_sqr < (byte*~) mul_tables_compare::$10 + if((boolean~) mul_tables_compare::$11) goto mul_tables_compare::@1 to:mul_tables_compare::@5 -mul_tables_compare::@10: scope:[mul_tables_compare] from mul_tables_compare::@5 +mul_tables_compare::@3: scope:[mul_tables_compare] from mul_tables_compare::@1 + *((byte*) BGCOL) ← (byte/signed byte/word/signed word) 2 + (void~) mul_tables_compare::$2 ← call print_cls + (void~) mul_tables_compare::$3 ← call print_str (string) "mul table mismatch at @" + (word~) mul_tables_compare::$4 ← ((word)) (byte*) mul_tables_compare::asm_sqr + (void~) mul_tables_compare::$5 ← call print_word (word~) mul_tables_compare::$4 + (void~) mul_tables_compare::$6 ← call print_str (string) " / @" + (word~) mul_tables_compare::$7 ← ((word)) (byte*) mul_tables_compare::kc_sqr + (void~) mul_tables_compare::$8 ← call print_word (word~) mul_tables_compare::$7 to:mul_tables_compare::@return -mul_tables_compare::@return: scope:[mul_tables_compare] from mul_tables_compare::@10 +mul_tables_compare::@return: scope:[mul_tables_compare] from mul_tables_compare::@3 mul_tables_compare::@5 return to:@return -@4: scope:[] from @3 +mul_tables_compare::@4: scope:[mul_tables_compare] from + to:mul_tables_compare::@2 +mul_tables_compare::@5: scope:[mul_tables_compare] from mul_tables_compare::@2 + to:mul_tables_compare::@return +@10: scope:[] from @9 call main to:@end -@end: scope:[] from @4 +@end: scope:[] from @10 +Removing unused procedure print_ln +Eliminating unused variable - keeping the call (void~) print_word::$1 +Eliminating unused variable - keeping the call (void~) print_word::$3 +Eliminating unused variable - keeping the call (void~) print_byte::$1 +Eliminating unused variable - keeping the call (void~) print_byte::$3 Eliminating unused variable - keeping the call (void~) main::$0 Eliminating unused variable - keeping the call (void~) main::$1 Eliminating unused variable - keeping the call (void~) main::$2 -Removing empty block init_mul_tables::@4 +Eliminating unused variable - keeping the call (void~) mul_tables_compare::$2 +Eliminating unused variable - keeping the call (void~) mul_tables_compare::$3 +Eliminating unused variable - keeping the call (void~) mul_tables_compare::$5 +Eliminating unused variable - keeping the call (void~) mul_tables_compare::$6 +Eliminating unused variable - keeping the call (void~) mul_tables_compare::$8 +Creating constant string variable for inline (const string) mul_tables_compare::str "mul table mismatch at @" +Creating constant string variable for inline (const string) mul_tables_compare::str1 " / @" +Removing empty block print_str::@4 +Removing empty block print_str::@3 +Removing empty block print_str::@5 +Removing empty block print_str::@6 +Removing empty block @1 +Removing empty block @2 Removing empty block @3 -Removing empty block mul_tables_compare::@10 +Removing empty block @4 +Removing empty block @5 +Removing empty block print_cls::@2 +Removing empty block @9 +Removing empty block mul_tables_compare::@4 +Removing empty block mul_tables_compare::@5 PROCEDURE MODIFY VARIABLE ANALYSIS +print_str modifies char_cursor +print_word modifies char_cursor +print_byte modifies char_cursor +print_char modifies char_cursor +main modifies char_cursor +mul_tables_compare modifies char_cursor Completing Phi functions... Completing Phi functions... @@ -368,43 +773,154 @@ Completing Phi functions... CONTROL FLOW GRAPH SSA WITH ASSIGNMENT CALL & RETURN @begin: scope:[] from + (byte*) line_cursor#0 ← ((byte*)) (word/signed word) 1024 + (byte*) char_cursor#0 ← (byte*) line_cursor#0 + to:@6 +print_str: scope:[print_str] from mul_tables_compare::@6 mul_tables_compare::@8 + (byte*) char_cursor#44 ← phi( mul_tables_compare::@6/(byte*) char_cursor#41 mul_tables_compare::@8/(byte*) char_cursor#14 ) + (byte*) print_str::str#5 ← phi( mul_tables_compare::@6/(byte*) print_str::str#1 mul_tables_compare::@8/(byte*) print_str::str#2 ) + to:print_str::@1 +print_str::@1: scope:[print_str] from print_str print_str::@2 + (byte*) char_cursor#37 ← phi( print_str/(byte*) char_cursor#44 print_str::@2/(byte*) char_cursor#1 ) + (byte*) print_str::str#3 ← phi( print_str/(byte*) print_str::str#5 print_str::@2/(byte*) print_str::str#0 ) + (boolean~) print_str::$0 ← *((byte*) print_str::str#3) != (byte) '@' + if((boolean~) print_str::$0) goto print_str::@2 + to:print_str::@return +print_str::@2: scope:[print_str] from print_str::@1 + (byte*) char_cursor#19 ← phi( print_str::@1/(byte*) char_cursor#37 ) + (byte*) print_str::str#4 ← phi( print_str::@1/(byte*) print_str::str#3 ) + *((byte*) char_cursor#19) ← *((byte*) print_str::str#4) + (byte*) char_cursor#1 ← ++ (byte*) char_cursor#19 + (byte*) print_str::str#0 ← ++ (byte*) print_str::str#4 + to:print_str::@1 +print_str::@return: scope:[print_str] from print_str::@1 + (byte*) char_cursor#20 ← phi( print_str::@1/(byte*) char_cursor#37 ) + (byte*) char_cursor#2 ← (byte*) char_cursor#20 + return + to:@return +print_word: scope:[print_word] from mul_tables_compare::@7 mul_tables_compare::@9 + (byte*) char_cursor#38 ← phi( mul_tables_compare::@7/(byte*) char_cursor#13 mul_tables_compare::@9/(byte*) char_cursor#15 ) + (word) print_word::w#2 ← phi( mul_tables_compare::@7/(word) print_word::w#0 mul_tables_compare::@9/(word) print_word::w#1 ) + (byte~) print_word::$0 ← > (word) print_word::w#2 + (byte) print_byte::b#0 ← (byte~) print_word::$0 + call print_byte param-assignment + to:print_word::@1 +print_word::@1: scope:[print_word] from print_word + (word) print_word::w#3 ← phi( print_word/(word) print_word::w#2 ) + (byte*) char_cursor#21 ← phi( print_word/(byte*) char_cursor#8 ) + (byte*) char_cursor#3 ← (byte*) char_cursor#21 + (byte~) print_word::$2 ← < (word) print_word::w#3 + (byte) print_byte::b#1 ← (byte~) print_word::$2 + call print_byte param-assignment + to:print_word::@2 +print_word::@2: scope:[print_word] from print_word::@1 + (byte*) char_cursor#22 ← phi( print_word::@1/(byte*) char_cursor#8 ) + (byte*) char_cursor#4 ← (byte*) char_cursor#22 + to:print_word::@return +print_word::@return: scope:[print_word] from print_word::@2 + (byte*) char_cursor#23 ← phi( print_word::@2/(byte*) char_cursor#4 ) + (byte*) char_cursor#5 ← (byte*) char_cursor#23 + return + to:@return +print_byte: scope:[print_byte] from print_word print_word::@1 + (byte*) char_cursor#39 ← phi( print_word/(byte*) char_cursor#38 print_word::@1/(byte*) char_cursor#3 ) + (byte) print_byte::b#2 ← phi( print_word/(byte) print_byte::b#0 print_word::@1/(byte) print_byte::b#1 ) + (byte[]) print_byte::hextab#0 ← { (byte) '0', (byte) '1', (byte) '2', (byte) '3', (byte) '4', (byte) '5', (byte) '6', (byte) '7', (byte) '8', (byte) '9', (byte) 'a', (byte) 'b', (byte) 'c', (byte) 'd', (byte) 'e', (byte) 'f' } + (byte~) print_byte::$0 ← (byte) print_byte::b#2 >> (byte/signed byte/word/signed word) 4 + (byte) print_char::ch#0 ← *((byte[]) print_byte::hextab#0 + (byte~) print_byte::$0) + call print_char param-assignment + to:print_byte::@1 +print_byte::@1: scope:[print_byte] from print_byte + (byte) print_byte::b#3 ← phi( print_byte/(byte) print_byte::b#2 ) + (byte*) char_cursor#24 ← phi( print_byte/(byte*) char_cursor#10 ) + (byte*) char_cursor#6 ← (byte*) char_cursor#24 + (byte~) print_byte::$2 ← (byte) print_byte::b#3 & (byte/signed byte/word/signed word) 15 + (byte) print_char::ch#1 ← *((byte[]) print_byte::hextab#0 + (byte~) print_byte::$2) + call print_char param-assignment + to:print_byte::@2 +print_byte::@2: scope:[print_byte] from print_byte::@1 + (byte*) char_cursor#25 ← phi( print_byte::@1/(byte*) char_cursor#10 ) + (byte*) char_cursor#7 ← (byte*) char_cursor#25 + to:print_byte::@return +print_byte::@return: scope:[print_byte] from print_byte::@2 + (byte*) char_cursor#26 ← phi( print_byte::@2/(byte*) char_cursor#7 ) + (byte*) char_cursor#8 ← (byte*) char_cursor#26 + return + to:@return +print_char: scope:[print_char] from print_byte print_byte::@1 + (byte*) char_cursor#27 ← phi( print_byte/(byte*) char_cursor#39 print_byte::@1/(byte*) char_cursor#6 ) + (byte) print_char::ch#2 ← phi( print_byte/(byte) print_char::ch#0 print_byte::@1/(byte) print_char::ch#1 ) + *((byte*) char_cursor#27) ← (byte) print_char::ch#2 + (byte*) char_cursor#9 ← ++ (byte*) char_cursor#27 + to:print_char::@return +print_char::@return: scope:[print_char] from print_char + (byte*) char_cursor#28 ← phi( print_char/(byte*) char_cursor#9 ) + (byte*) char_cursor#10 ← (byte*) char_cursor#28 + return + to:@return +print_cls: scope:[print_cls] from mul_tables_compare::@3 + (byte*) print_cls::sc#0 ← ((byte*)) (word/signed word) 1024 + to:print_cls::@1 +print_cls::@1: scope:[print_cls] from print_cls print_cls::@1 + (byte*) print_cls::sc#2 ← phi( print_cls/(byte*) print_cls::sc#0 print_cls::@1/(byte*) print_cls::sc#1 ) + *((byte*) print_cls::sc#2) ← (byte) ' ' + (byte*) print_cls::sc#1 ← ++ (byte*) print_cls::sc#2 + (word/signed word~) print_cls::$0 ← (word/signed word) 1024 + (word/signed word) 1000 + (boolean~) print_cls::$1 ← (byte*) print_cls::sc#1 != (word/signed word~) print_cls::$0 + if((boolean~) print_cls::$1) goto print_cls::@1 + to:print_cls::@return +print_cls::@return: scope:[print_cls] from print_cls::@1 + return + to:@return +@6: scope:[] from @begin + (byte*) char_cursor#52 ← phi( @begin/(byte*) char_cursor#0 ) (byte*) BGCOL#0 ← ((byte*)) (word) 53281 - to:@1 -main: scope:[main] from @4 - (byte*) BGCOL#13 ← phi( @4/(byte*) BGCOL#14 ) + to:@7 +main: scope:[main] from @10 + (byte*) BGCOL#7 ← phi( @10/(byte*) BGCOL#8 ) + (byte*) char_cursor#49 ← phi( @10/(byte*) char_cursor#43 ) call init_mul_tables param-assignment to:main::@1 main::@1: scope:[main] from main - (byte*) BGCOL#11 ← phi( main/(byte*) BGCOL#13 ) + (byte*) BGCOL#5 ← phi( main/(byte*) BGCOL#7 ) + (byte*) char_cursor#45 ← phi( main/(byte*) char_cursor#49 ) call init_mul_tables_asm param-assignment to:main::@2 main::@2: scope:[main] from main::@1 - (byte*) BGCOL#6 ← phi( main::@1/(byte*) BGCOL#11 ) + (byte*) BGCOL#3 ← phi( main::@1/(byte*) BGCOL#5 ) + (byte*) char_cursor#40 ← phi( main::@1/(byte*) char_cursor#45 ) call mul_tables_compare param-assignment to:main::@3 main::@3: scope:[main] from main::@2 + (byte*) char_cursor#29 ← phi( main::@2/(byte*) char_cursor#17 ) + (byte*) char_cursor#11 ← (byte*) char_cursor#29 to:main::@return main::@return: scope:[main] from main::@3 + (byte*) char_cursor#30 ← phi( main::@3/(byte*) char_cursor#11 ) + (byte*) char_cursor#12 ← (byte*) char_cursor#30 return to:@return -@1: scope:[] from @begin - (byte*) BGCOL#16 ← phi( @begin/(byte*) BGCOL#0 ) - (byte[512]) mul_sqr_lo#0 ← { fill( 512, 0) } - (byte[512]) mul_sqr_hi#0 ← { fill( 512, 0) } - to:@2 +@7: scope:[] from @6 + (byte*) BGCOL#10 ← phi( @6/(byte*) BGCOL#0 ) + (byte*) char_cursor#50 ← phi( @6/(byte*) char_cursor#52 ) + (byte[512]) mul_sqr1_lo#0 ← { fill( 512, 0) } + (byte[512]) mul_sqr1_hi#0 ← { fill( 512, 0) } + (byte[512]) mul_sqr2_lo#0 ← { fill( 512, 0) } + (byte[512]) mul_sqr2_hi#0 ← { fill( 512, 0) } + to:@8 init_mul_tables: scope:[init_mul_tables] from main (word) init_mul_tables::sqr#0 ← (byte/signed byte/word/signed word) 0 (byte) init_mul_tables::x_2#0 ← (byte/signed byte/word/signed word) 0 (byte) init_mul_tables::c#0 ← (byte/signed byte/word/signed word) 0 - (byte*~) init_mul_tables::$0 ← (byte[512]) mul_sqr_hi#0 + (byte/signed byte/word/signed word) 1 - (byte*) init_mul_tables::sqr_hi#0 ← (byte*~) init_mul_tables::$0 - (byte*~) init_mul_tables::$1 ← (byte[512]) mul_sqr_lo#0 + (byte/signed byte/word/signed word) 1 - (byte*) init_mul_tables::sqr_lo#0 ← (byte*~) init_mul_tables::$1 + (byte*~) init_mul_tables::$0 ← (byte[512]) mul_sqr1_hi#0 + (byte/signed byte/word/signed word) 1 + (byte*) init_mul_tables::sqr1_hi#0 ← (byte*~) init_mul_tables::$0 + (byte*~) init_mul_tables::$1 ← (byte[512]) mul_sqr1_lo#0 + (byte/signed byte/word/signed word) 1 + (byte*) init_mul_tables::sqr1_lo#0 ← (byte*~) init_mul_tables::$1 to:init_mul_tables::@1 init_mul_tables::@1: scope:[init_mul_tables] from init_mul_tables init_mul_tables::@2 (byte) init_mul_tables::x_2#4 ← phi( init_mul_tables/(byte) init_mul_tables::x_2#0 init_mul_tables::@2/(byte) init_mul_tables::x_2#2 ) - (byte*) init_mul_tables::sqr_hi#3 ← phi( init_mul_tables/(byte*) init_mul_tables::sqr_hi#0 init_mul_tables::@2/(byte*) init_mul_tables::sqr_hi#1 ) - (byte*) init_mul_tables::sqr_lo#3 ← phi( init_mul_tables/(byte*) init_mul_tables::sqr_lo#0 init_mul_tables::@2/(byte*) init_mul_tables::sqr_lo#1 ) + (byte*) init_mul_tables::sqr1_hi#3 ← phi( init_mul_tables/(byte*) init_mul_tables::sqr1_hi#0 init_mul_tables::@2/(byte*) init_mul_tables::sqr1_hi#1 ) + (byte*) init_mul_tables::sqr1_lo#3 ← phi( init_mul_tables/(byte*) init_mul_tables::sqr1_lo#0 init_mul_tables::@2/(byte*) init_mul_tables::sqr1_lo#1 ) (word) init_mul_tables::sqr#5 ← phi( init_mul_tables/(word) init_mul_tables::sqr#0 init_mul_tables::@2/(word) init_mul_tables::sqr#1 ) (byte) init_mul_tables::c#2 ← phi( init_mul_tables/(byte) init_mul_tables::c#0 init_mul_tables::@2/(byte) init_mul_tables::c#3 ) (byte) init_mul_tables::c#1 ← ++ (byte) init_mul_tables::c#2 @@ -412,140 +928,201 @@ init_mul_tables::@1: scope:[init_mul_tables] from init_mul_tables init_mul_tabl (boolean~) init_mul_tables::$3 ← (byte~) init_mul_tables::$2 == (byte/signed byte/word/signed word) 0 (boolean~) init_mul_tables::$4 ← ! (boolean~) init_mul_tables::$3 if((boolean~) init_mul_tables::$4) goto init_mul_tables::@2 - to:init_mul_tables::@3 -init_mul_tables::@2: scope:[init_mul_tables] from init_mul_tables::@1 init_mul_tables::@3 - (byte) init_mul_tables::c#3 ← phi( init_mul_tables::@1/(byte) init_mul_tables::c#1 init_mul_tables::@3/(byte) init_mul_tables::c#4 ) - (byte) init_mul_tables::x_2#2 ← phi( init_mul_tables::@1/(byte) init_mul_tables::x_2#4 init_mul_tables::@3/(byte) init_mul_tables::x_2#1 ) - (byte*) init_mul_tables::sqr_hi#2 ← phi( init_mul_tables::@1/(byte*) init_mul_tables::sqr_hi#3 init_mul_tables::@3/(byte*) init_mul_tables::sqr_hi#4 ) - (byte*) init_mul_tables::sqr_lo#2 ← phi( init_mul_tables::@1/(byte*) init_mul_tables::sqr_lo#3 init_mul_tables::@3/(byte*) init_mul_tables::sqr_lo#4 ) - (word) init_mul_tables::sqr#3 ← phi( init_mul_tables::@1/(word) init_mul_tables::sqr#5 init_mul_tables::@3/(word) init_mul_tables::sqr#2 ) + to:init_mul_tables::@5 +init_mul_tables::@2: scope:[init_mul_tables] from init_mul_tables::@1 init_mul_tables::@5 + (byte) init_mul_tables::c#3 ← phi( init_mul_tables::@1/(byte) init_mul_tables::c#1 init_mul_tables::@5/(byte) init_mul_tables::c#4 ) + (byte) init_mul_tables::x_2#2 ← phi( init_mul_tables::@1/(byte) init_mul_tables::x_2#4 init_mul_tables::@5/(byte) init_mul_tables::x_2#1 ) + (byte*) init_mul_tables::sqr1_hi#2 ← phi( init_mul_tables::@1/(byte*) init_mul_tables::sqr1_hi#3 init_mul_tables::@5/(byte*) init_mul_tables::sqr1_hi#4 ) + (byte*) init_mul_tables::sqr1_lo#2 ← phi( init_mul_tables::@1/(byte*) init_mul_tables::sqr1_lo#3 init_mul_tables::@5/(byte*) init_mul_tables::sqr1_lo#4 ) + (word) init_mul_tables::sqr#3 ← phi( init_mul_tables::@1/(word) init_mul_tables::sqr#5 init_mul_tables::@5/(word) init_mul_tables::sqr#2 ) (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 - *((byte*) init_mul_tables::sqr_lo#2) ← (byte~) init_mul_tables::$5 + *((byte*) init_mul_tables::sqr1_lo#2) ← (byte~) init_mul_tables::$5 (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 - *((byte*) init_mul_tables::sqr_hi#2) ← (byte~) init_mul_tables::$6 - (byte*) init_mul_tables::sqr_hi#1 ← ++ (byte*) init_mul_tables::sqr_hi#2 + *((byte*) init_mul_tables::sqr1_hi#2) ← (byte~) init_mul_tables::$6 + (byte*) init_mul_tables::sqr1_hi#1 ← ++ (byte*) init_mul_tables::sqr1_hi#2 (word~) init_mul_tables::$7 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 (word) init_mul_tables::sqr#1 ← (word~) init_mul_tables::$7 - (byte*) init_mul_tables::sqr_lo#1 ← ++ (byte*) init_mul_tables::sqr_lo#2 - (byte*~) init_mul_tables::$8 ← (byte[512]) mul_sqr_lo#0 + (word/signed word) 512 - (boolean~) init_mul_tables::$9 ← (byte*) init_mul_tables::sqr_lo#1 != (byte*~) init_mul_tables::$8 + (byte*) init_mul_tables::sqr1_lo#1 ← ++ (byte*) init_mul_tables::sqr1_lo#2 + (byte*~) init_mul_tables::$8 ← (byte[512]) mul_sqr1_lo#0 + (word/signed word) 512 + (boolean~) init_mul_tables::$9 ← (byte*) init_mul_tables::sqr1_lo#1 != (byte*~) init_mul_tables::$8 if((boolean~) init_mul_tables::$9) goto init_mul_tables::@1 - to:init_mul_tables::@return -init_mul_tables::@3: scope:[init_mul_tables] from init_mul_tables::@1 + to:init_mul_tables::@6 +init_mul_tables::@5: scope:[init_mul_tables] from init_mul_tables::@1 (byte) init_mul_tables::c#4 ← phi( init_mul_tables::@1/(byte) init_mul_tables::c#1 ) - (byte*) init_mul_tables::sqr_hi#4 ← phi( init_mul_tables::@1/(byte*) init_mul_tables::sqr_hi#3 ) - (byte*) init_mul_tables::sqr_lo#4 ← phi( init_mul_tables::@1/(byte*) init_mul_tables::sqr_lo#3 ) + (byte*) init_mul_tables::sqr1_hi#4 ← phi( init_mul_tables::@1/(byte*) init_mul_tables::sqr1_hi#3 ) + (byte*) init_mul_tables::sqr1_lo#4 ← phi( init_mul_tables::@1/(byte*) init_mul_tables::sqr1_lo#3 ) (word) init_mul_tables::sqr#4 ← phi( init_mul_tables::@1/(word) init_mul_tables::sqr#5 ) (byte) init_mul_tables::x_2#3 ← phi( init_mul_tables::@1/(byte) init_mul_tables::x_2#4 ) (byte) init_mul_tables::x_2#1 ← ++ (byte) init_mul_tables::x_2#3 (word) init_mul_tables::sqr#2 ← ++ (word) init_mul_tables::sqr#4 to:init_mul_tables::@2 -init_mul_tables::@return: scope:[init_mul_tables] from init_mul_tables::@2 +init_mul_tables::@6: scope:[init_mul_tables] from init_mul_tables::@2 + (signed byte/signed word~) init_mul_tables::$10 ← - (byte/signed byte/word/signed word) 1 + (byte~) init_mul_tables::$11 ← ((byte)) (signed byte/signed word~) init_mul_tables::$10 + (byte) init_mul_tables::x_255#0 ← (byte~) init_mul_tables::$11 + (byte) init_mul_tables::dir#0 ← (byte/word/signed word) 255 + (byte*) init_mul_tables::sqr2_hi#0 ← (byte[512]) mul_sqr2_hi#0 + (byte*) init_mul_tables::sqr2_lo#0 ← (byte[512]) mul_sqr2_lo#0 + to:init_mul_tables::@3 +init_mul_tables::@3: scope:[init_mul_tables] from init_mul_tables::@4 init_mul_tables::@6 + (byte) init_mul_tables::dir#2 ← phi( init_mul_tables::@4/(byte) init_mul_tables::dir#3 init_mul_tables::@6/(byte) init_mul_tables::dir#0 ) + (byte*) init_mul_tables::sqr2_hi#2 ← phi( init_mul_tables::@4/(byte*) init_mul_tables::sqr2_hi#3 init_mul_tables::@6/(byte*) init_mul_tables::sqr2_hi#0 ) + (byte*) init_mul_tables::sqr2_lo#2 ← phi( init_mul_tables::@4/(byte*) init_mul_tables::sqr2_lo#1 init_mul_tables::@6/(byte*) init_mul_tables::sqr2_lo#0 ) + (byte) init_mul_tables::x_255#2 ← phi( init_mul_tables::@4/(byte) init_mul_tables::x_255#3 init_mul_tables::@6/(byte) init_mul_tables::x_255#0 ) + *((byte*) init_mul_tables::sqr2_lo#2) ← *((byte[512]) mul_sqr1_lo#0 + (byte) init_mul_tables::x_255#2) + *((byte*) init_mul_tables::sqr2_hi#2) ← *((byte[512]) mul_sqr1_hi#0 + (byte) init_mul_tables::x_255#2) + (byte*) init_mul_tables::sqr2_hi#1 ← ++ (byte*) init_mul_tables::sqr2_hi#2 + (byte/word~) init_mul_tables::$12 ← (byte) init_mul_tables::x_255#2 + (byte) init_mul_tables::dir#2 + (byte) init_mul_tables::x_255#1 ← (byte/word~) init_mul_tables::$12 + (boolean~) init_mul_tables::$13 ← (byte) init_mul_tables::x_255#1 == (byte/signed byte/word/signed word) 0 + (boolean~) init_mul_tables::$14 ← ! (boolean~) init_mul_tables::$13 + if((boolean~) init_mul_tables::$14) goto init_mul_tables::@4 + to:init_mul_tables::@7 +init_mul_tables::@4: scope:[init_mul_tables] from init_mul_tables::@3 init_mul_tables::@7 + (byte) init_mul_tables::dir#3 ← phi( init_mul_tables::@3/(byte) init_mul_tables::dir#2 init_mul_tables::@7/(byte) init_mul_tables::dir#1 ) + (byte*) init_mul_tables::sqr2_hi#3 ← phi( init_mul_tables::@3/(byte*) init_mul_tables::sqr2_hi#1 init_mul_tables::@7/(byte*) init_mul_tables::sqr2_hi#4 ) + (byte) init_mul_tables::x_255#3 ← phi( init_mul_tables::@3/(byte) init_mul_tables::x_255#1 init_mul_tables::@7/(byte) init_mul_tables::x_255#4 ) + (byte*) init_mul_tables::sqr2_lo#3 ← phi( init_mul_tables::@3/(byte*) init_mul_tables::sqr2_lo#2 init_mul_tables::@7/(byte*) init_mul_tables::sqr2_lo#4 ) + (byte*) init_mul_tables::sqr2_lo#1 ← ++ (byte*) init_mul_tables::sqr2_lo#3 + (byte*~) init_mul_tables::$15 ← (byte[512]) mul_sqr2_lo#0 + (word/signed word) 511 + (boolean~) init_mul_tables::$16 ← (byte*) init_mul_tables::sqr2_lo#1 != (byte*~) init_mul_tables::$15 + if((boolean~) init_mul_tables::$16) goto init_mul_tables::@3 + to:init_mul_tables::@8 +init_mul_tables::@7: scope:[init_mul_tables] from init_mul_tables::@3 + (byte*) init_mul_tables::sqr2_hi#4 ← phi( init_mul_tables::@3/(byte*) init_mul_tables::sqr2_hi#1 ) + (byte) init_mul_tables::x_255#4 ← phi( init_mul_tables::@3/(byte) init_mul_tables::x_255#1 ) + (byte*) init_mul_tables::sqr2_lo#4 ← phi( init_mul_tables::@3/(byte*) init_mul_tables::sqr2_lo#2 ) + (byte) init_mul_tables::dir#1 ← (byte/signed byte/word/signed word) 1 + to:init_mul_tables::@4 +init_mul_tables::@8: scope:[init_mul_tables] from init_mul_tables::@4 + (byte*~) init_mul_tables::$17 ← (byte[512]) mul_sqr2_lo#0 + (word/signed word) 511 + (byte*~) init_mul_tables::$18 ← (byte[512]) mul_sqr1_lo#0 + (word/signed word) 256 + *((byte*~) init_mul_tables::$17) ← *((byte*~) init_mul_tables::$18) + (byte*~) init_mul_tables::$19 ← (byte[512]) mul_sqr2_hi#0 + (word/signed word) 511 + (byte*~) init_mul_tables::$20 ← (byte[512]) mul_sqr1_hi#0 + (word/signed word) 256 + *((byte*~) init_mul_tables::$19) ← *((byte*~) init_mul_tables::$20) + to:init_mul_tables::@return +init_mul_tables::@return: scope:[init_mul_tables] from init_mul_tables::@8 return to:@return -@2: scope:[] from @1 - (byte*) BGCOL#15 ← phi( @1/(byte*) BGCOL#16 ) - (byte[512]) asm_mul_sqr_lo#0 ← { fill( 512, 0) } - (byte[512]) asm_mul_sqr_hi#0 ← { fill( 512, 0) } - to:@4 +@8: scope:[] from @7 + (byte*) BGCOL#9 ← phi( @7/(byte*) BGCOL#10 ) + (byte*) char_cursor#48 ← phi( @7/(byte*) char_cursor#50 ) + (byte[512]) asm_mul_sqr1_lo#0 ← { fill( 512, 0) } + (byte[512]) asm_mul_sqr1_hi#0 ← { fill( 512, 0) } + (byte[512]) asm_mul_sqr2_lo#0 ← { fill( 512, 0) } + (byte[512]) asm_mul_sqr2_hi#0 ← { fill( 512, 0) } + to:@10 init_mul_tables_asm: scope:[init_mul_tables_asm] from main::@1 - asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr_lo,xbnelb1incml0+2incml1+2clcinybnelb1 } + asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr1_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr1_lo,xbnelb1incml0+2incml1+2clcinybnelb1ldx#$00ldy#$ff!:ldaasm_mul_sqr1_hi+1,xstaasm_mul_sqr2_hi+$100,xldaasm_mul_sqr1_hi,xstaasm_mul_sqr2_hi,yldaasm_mul_sqr1_lo+1,xstaasm_mul_sqr2_lo+$100,xldaasm_mul_sqr1_lo,xstaasm_mul_sqr2_lo,ydeyinxbne!- } + (byte*) init_mul_tables_asm::mem#0 ← ((byte*)) (byte/word/signed word) 255 + *((byte*) init_mul_tables_asm::mem#0) ← *((byte[512]) asm_mul_sqr1_lo#0) + *((byte*) init_mul_tables_asm::mem#0) ← *((byte[512]) asm_mul_sqr1_hi#0) + *((byte*) init_mul_tables_asm::mem#0) ← *((byte[512]) asm_mul_sqr2_lo#0) + *((byte*) init_mul_tables_asm::mem#0) ← *((byte[512]) asm_mul_sqr2_hi#0) to:init_mul_tables_asm::@return init_mul_tables_asm::@return: scope:[init_mul_tables_asm] from init_mul_tables_asm return to:@return mul_tables_compare: scope:[mul_tables_compare] from main::@2 - (byte*) BGCOL#1 ← phi( main::@2/(byte*) BGCOL#6 ) + (byte*) char_cursor#51 ← phi( main::@2/(byte*) char_cursor#40 ) + (byte*) BGCOL#1 ← phi( main::@2/(byte*) BGCOL#3 ) *((byte*) BGCOL#1) ← (byte/signed byte/word/signed word) 5 - (byte) mul_tables_compare::i#0 ← (byte/signed byte/word/signed word) 0 + (byte*) mul_tables_compare::asm_sqr#0 ← (byte[512]) asm_mul_sqr1_lo#0 + (byte*) mul_tables_compare::kc_sqr#0 ← (byte[512]) mul_sqr1_lo#0 to:mul_tables_compare::@1 -mul_tables_compare::@1: scope:[mul_tables_compare] from mul_tables_compare mul_tables_compare::@5 - (byte*) BGCOL#7 ← phi( mul_tables_compare/(byte*) BGCOL#1 mul_tables_compare::@5/(byte*) BGCOL#12 ) - (byte) mul_tables_compare::i#2 ← phi( mul_tables_compare/(byte) mul_tables_compare::i#0 mul_tables_compare::@5/(byte) mul_tables_compare::i#1 ) - (boolean~) mul_tables_compare::$0 ← *((byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#2) != *((byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#2) +mul_tables_compare::@1: scope:[mul_tables_compare] from mul_tables_compare mul_tables_compare::@2 + (byte*) char_cursor#46 ← phi( mul_tables_compare/(byte*) char_cursor#51 mul_tables_compare::@2/(byte*) char_cursor#42 ) + (byte*) BGCOL#4 ← phi( mul_tables_compare/(byte*) BGCOL#1 mul_tables_compare::@2/(byte*) BGCOL#6 ) + (byte*) mul_tables_compare::asm_sqr#2 ← phi( mul_tables_compare/(byte*) mul_tables_compare::asm_sqr#0 mul_tables_compare::@2/(byte*) mul_tables_compare::asm_sqr#1 ) + (byte*) mul_tables_compare::kc_sqr#2 ← phi( mul_tables_compare/(byte*) mul_tables_compare::kc_sqr#0 mul_tables_compare::@2/(byte*) mul_tables_compare::kc_sqr#1 ) + (boolean~) mul_tables_compare::$0 ← *((byte*) mul_tables_compare::kc_sqr#2) != *((byte*) mul_tables_compare::asm_sqr#2) (boolean~) mul_tables_compare::$1 ← ! (boolean~) mul_tables_compare::$0 if((boolean~) mul_tables_compare::$1) goto mul_tables_compare::@2 - to:mul_tables_compare::@6 -mul_tables_compare::@2: scope:[mul_tables_compare] from mul_tables_compare::@1 mul_tables_compare::@6 - (byte*) BGCOL#8 ← phi( mul_tables_compare::@1/(byte*) BGCOL#7 mul_tables_compare::@6/(byte*) BGCOL#2 ) - (byte) mul_tables_compare::i#3 ← phi( mul_tables_compare::@1/(byte) mul_tables_compare::i#2 mul_tables_compare::@6/(byte) mul_tables_compare::i#7 ) - (byte*~) mul_tables_compare::$2 ← (byte[512]) mul_sqr_hi#0 + (word/signed word) 256 - (byte*~) mul_tables_compare::$3 ← (byte[512]) asm_mul_sqr_hi#0 + (word/signed word) 256 - (boolean~) mul_tables_compare::$4 ← *((byte*~) mul_tables_compare::$2 + (byte) mul_tables_compare::i#3) != *((byte*~) mul_tables_compare::$3 + (byte) mul_tables_compare::i#3) - (boolean~) mul_tables_compare::$5 ← ! (boolean~) mul_tables_compare::$4 - if((boolean~) mul_tables_compare::$5) goto mul_tables_compare::@3 - to:mul_tables_compare::@7 -mul_tables_compare::@6: scope:[mul_tables_compare] from mul_tables_compare::@1 - (byte) mul_tables_compare::i#7 ← phi( mul_tables_compare::@1/(byte) mul_tables_compare::i#2 ) - (byte*) BGCOL#2 ← phi( mul_tables_compare::@1/(byte*) BGCOL#7 ) - *((byte*) BGCOL#2) ← (byte/signed byte/word/signed word) 2 - to:mul_tables_compare::@2 -mul_tables_compare::@3: scope:[mul_tables_compare] from mul_tables_compare::@2 mul_tables_compare::@7 - (byte*) BGCOL#9 ← phi( mul_tables_compare::@2/(byte*) BGCOL#8 mul_tables_compare::@7/(byte*) BGCOL#3 ) - (byte) mul_tables_compare::i#4 ← phi( mul_tables_compare::@2/(byte) mul_tables_compare::i#3 mul_tables_compare::@7/(byte) mul_tables_compare::i#8 ) - (boolean~) mul_tables_compare::$6 ← *((byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#4) != *((byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#4) - (boolean~) mul_tables_compare::$7 ← ! (boolean~) mul_tables_compare::$6 - if((boolean~) mul_tables_compare::$7) goto mul_tables_compare::@4 - to:mul_tables_compare::@8 -mul_tables_compare::@7: scope:[mul_tables_compare] from mul_tables_compare::@2 - (byte) mul_tables_compare::i#8 ← phi( mul_tables_compare::@2/(byte) mul_tables_compare::i#3 ) - (byte*) BGCOL#3 ← phi( mul_tables_compare::@2/(byte*) BGCOL#8 ) - *((byte*) BGCOL#3) ← (byte/signed byte/word/signed word) 2 to:mul_tables_compare::@3 -mul_tables_compare::@4: scope:[mul_tables_compare] from mul_tables_compare::@3 mul_tables_compare::@8 - (byte*) BGCOL#10 ← phi( mul_tables_compare::@3/(byte*) BGCOL#9 mul_tables_compare::@8/(byte*) BGCOL#4 ) - (byte) mul_tables_compare::i#5 ← phi( mul_tables_compare::@3/(byte) mul_tables_compare::i#4 mul_tables_compare::@8/(byte) mul_tables_compare::i#9 ) - (byte*~) mul_tables_compare::$8 ← (byte[512]) mul_sqr_hi#0 + (word/signed word) 256 - (byte*~) mul_tables_compare::$9 ← (byte[512]) asm_mul_sqr_hi#0 + (word/signed word) 256 - (boolean~) mul_tables_compare::$10 ← *((byte*~) mul_tables_compare::$8 + (byte) mul_tables_compare::i#5) != *((byte*~) mul_tables_compare::$9 + (byte) mul_tables_compare::i#5) - (boolean~) mul_tables_compare::$11 ← ! (boolean~) mul_tables_compare::$10 - if((boolean~) mul_tables_compare::$11) goto mul_tables_compare::@5 - to:mul_tables_compare::@9 -mul_tables_compare::@8: scope:[mul_tables_compare] from mul_tables_compare::@3 - (byte) mul_tables_compare::i#9 ← phi( mul_tables_compare::@3/(byte) mul_tables_compare::i#4 ) - (byte*) BGCOL#4 ← phi( mul_tables_compare::@3/(byte*) BGCOL#9 ) - *((byte*) BGCOL#4) ← (byte/signed byte/word/signed word) 2 - to:mul_tables_compare::@4 -mul_tables_compare::@5: scope:[mul_tables_compare] from mul_tables_compare::@4 mul_tables_compare::@9 - (byte*) BGCOL#12 ← phi( mul_tables_compare::@4/(byte*) BGCOL#10 mul_tables_compare::@9/(byte*) BGCOL#5 ) - (byte) mul_tables_compare::i#6 ← phi( mul_tables_compare::@4/(byte) mul_tables_compare::i#5 mul_tables_compare::@9/(byte) mul_tables_compare::i#10 ) - (byte) mul_tables_compare::i#1 ← ++ (byte) mul_tables_compare::i#6 - (boolean~) mul_tables_compare::$12 ← (byte) mul_tables_compare::i#1 != (byte/signed byte/word/signed word) 0 - if((boolean~) mul_tables_compare::$12) goto mul_tables_compare::@1 +mul_tables_compare::@2: scope:[mul_tables_compare] from mul_tables_compare::@1 + (byte*) BGCOL#6 ← phi( mul_tables_compare::@1/(byte*) BGCOL#4 ) + (byte*) char_cursor#42 ← phi( mul_tables_compare::@1/(byte*) char_cursor#46 ) + (byte*) mul_tables_compare::kc_sqr#3 ← phi( mul_tables_compare::@1/(byte*) mul_tables_compare::kc_sqr#2 ) + (byte*) mul_tables_compare::asm_sqr#3 ← phi( mul_tables_compare::@1/(byte*) mul_tables_compare::asm_sqr#2 ) + (byte*) mul_tables_compare::asm_sqr#1 ← ++ (byte*) mul_tables_compare::asm_sqr#3 + (byte*) mul_tables_compare::kc_sqr#1 ← ++ (byte*) mul_tables_compare::kc_sqr#3 + (word/signed word~) mul_tables_compare::$9 ← (word/signed word) 512 * (byte/signed byte/word/signed word) 4 + (byte*~) mul_tables_compare::$10 ← (byte[512]) mul_sqr1_lo#0 + (word/signed word~) mul_tables_compare::$9 + (boolean~) mul_tables_compare::$11 ← (byte*) mul_tables_compare::kc_sqr#1 < (byte*~) mul_tables_compare::$10 + if((boolean~) mul_tables_compare::$11) goto mul_tables_compare::@1 to:mul_tables_compare::@return -mul_tables_compare::@9: scope:[mul_tables_compare] from mul_tables_compare::@4 - (byte) mul_tables_compare::i#10 ← phi( mul_tables_compare::@4/(byte) mul_tables_compare::i#5 ) - (byte*) BGCOL#5 ← phi( mul_tables_compare::@4/(byte*) BGCOL#10 ) - *((byte*) BGCOL#5) ← (byte/signed byte/word/signed word) 2 - to:mul_tables_compare::@5 -mul_tables_compare::@return: scope:[mul_tables_compare] from mul_tables_compare::@5 +mul_tables_compare::@3: scope:[mul_tables_compare] from mul_tables_compare::@1 + (byte*) mul_tables_compare::kc_sqr#8 ← phi( mul_tables_compare::@1/(byte*) mul_tables_compare::kc_sqr#2 ) + (byte*) mul_tables_compare::asm_sqr#6 ← phi( mul_tables_compare::@1/(byte*) mul_tables_compare::asm_sqr#2 ) + (byte*) char_cursor#47 ← phi( mul_tables_compare::@1/(byte*) char_cursor#46 ) + (byte*) BGCOL#2 ← phi( mul_tables_compare::@1/(byte*) BGCOL#4 ) + *((byte*) BGCOL#2) ← (byte/signed byte/word/signed word) 2 + call print_cls param-assignment + to:mul_tables_compare::@6 +mul_tables_compare::@6: scope:[mul_tables_compare] from mul_tables_compare::@3 + (byte*) mul_tables_compare::kc_sqr#7 ← phi( mul_tables_compare::@3/(byte*) mul_tables_compare::kc_sqr#8 ) + (byte*) mul_tables_compare::asm_sqr#5 ← phi( mul_tables_compare::@3/(byte*) mul_tables_compare::asm_sqr#6 ) + (byte*) char_cursor#41 ← phi( mul_tables_compare::@3/(byte*) char_cursor#47 ) + (byte*) print_str::str#1 ← (const string) mul_tables_compare::str + call print_str param-assignment + to:mul_tables_compare::@7 +mul_tables_compare::@7: scope:[mul_tables_compare] from mul_tables_compare::@6 + (byte*) mul_tables_compare::kc_sqr#6 ← phi( mul_tables_compare::@6/(byte*) mul_tables_compare::kc_sqr#7 ) + (byte*) mul_tables_compare::asm_sqr#4 ← phi( mul_tables_compare::@6/(byte*) mul_tables_compare::asm_sqr#5 ) + (byte*) char_cursor#31 ← phi( mul_tables_compare::@6/(byte*) char_cursor#2 ) + (byte*) char_cursor#13 ← (byte*) char_cursor#31 + (word~) mul_tables_compare::$4 ← ((word)) (byte*) mul_tables_compare::asm_sqr#4 + (word) print_word::w#0 ← (word~) mul_tables_compare::$4 + call print_word param-assignment + to:mul_tables_compare::@8 +mul_tables_compare::@8: scope:[mul_tables_compare] from mul_tables_compare::@7 + (byte*) mul_tables_compare::kc_sqr#5 ← phi( mul_tables_compare::@7/(byte*) mul_tables_compare::kc_sqr#6 ) + (byte*) char_cursor#32 ← phi( mul_tables_compare::@7/(byte*) char_cursor#5 ) + (byte*) char_cursor#14 ← (byte*) char_cursor#32 + (byte*) print_str::str#2 ← (const string) mul_tables_compare::str1 + call print_str param-assignment + to:mul_tables_compare::@9 +mul_tables_compare::@9: scope:[mul_tables_compare] from mul_tables_compare::@8 + (byte*) mul_tables_compare::kc_sqr#4 ← phi( mul_tables_compare::@8/(byte*) mul_tables_compare::kc_sqr#5 ) + (byte*) char_cursor#33 ← phi( mul_tables_compare::@8/(byte*) char_cursor#2 ) + (byte*) char_cursor#15 ← (byte*) char_cursor#33 + (word~) mul_tables_compare::$7 ← ((word)) (byte*) mul_tables_compare::kc_sqr#4 + (word) print_word::w#1 ← (word~) mul_tables_compare::$7 + call print_word param-assignment + to:mul_tables_compare::@10 +mul_tables_compare::@10: scope:[mul_tables_compare] from mul_tables_compare::@9 + (byte*) char_cursor#34 ← phi( mul_tables_compare::@9/(byte*) char_cursor#5 ) + (byte*) char_cursor#16 ← (byte*) char_cursor#34 + to:mul_tables_compare::@return +mul_tables_compare::@return: scope:[mul_tables_compare] from mul_tables_compare::@10 mul_tables_compare::@2 + (byte*) char_cursor#35 ← phi( mul_tables_compare::@10/(byte*) char_cursor#16 mul_tables_compare::@2/(byte*) char_cursor#42 ) + (byte*) char_cursor#17 ← (byte*) char_cursor#35 return to:@return -@4: scope:[] from @2 - (byte*) BGCOL#14 ← phi( @2/(byte*) BGCOL#15 ) +@10: scope:[] from @8 + (byte*) BGCOL#8 ← phi( @8/(byte*) BGCOL#9 ) + (byte*) char_cursor#43 ← phi( @8/(byte*) char_cursor#48 ) call main param-assignment - to:@5 -@5: scope:[] from @4 + to:@11 +@11: scope:[] from @10 + (byte*) char_cursor#36 ← phi( @10/(byte*) char_cursor#12 ) + (byte*) char_cursor#18 ← (byte*) char_cursor#36 to:@end -@end: scope:[] from @5 +@end: scope:[] from @11 SYMBOL TABLE SSA -(label) @1 -(label) @2 -(label) @4 -(label) @5 +(label) @10 +(label) @11 +(label) @6 +(label) @7 +(label) @8 (label) @begin (label) @end (byte*) BGCOL (byte*) BGCOL#0 (byte*) BGCOL#1 (byte*) BGCOL#10 -(byte*) BGCOL#11 -(byte*) BGCOL#12 -(byte*) BGCOL#13 -(byte*) BGCOL#14 -(byte*) BGCOL#15 -(byte*) BGCOL#16 (byte*) BGCOL#2 (byte*) BGCOL#3 (byte*) BGCOL#4 @@ -554,14 +1131,83 @@ SYMBOL TABLE SSA (byte*) BGCOL#7 (byte*) BGCOL#8 (byte*) BGCOL#9 -(byte[512]) asm_mul_sqr_hi -(byte[512]) asm_mul_sqr_hi#0 -(byte[512]) asm_mul_sqr_lo -(byte[512]) asm_mul_sqr_lo#0 +(byte[512]) asm_mul_sqr1_hi +(byte[512]) asm_mul_sqr1_hi#0 +(byte[512]) asm_mul_sqr1_lo +(byte[512]) asm_mul_sqr1_lo#0 +(byte[512]) asm_mul_sqr2_hi +(byte[512]) asm_mul_sqr2_hi#0 +(byte[512]) asm_mul_sqr2_lo +(byte[512]) asm_mul_sqr2_lo#0 +(byte*) char_cursor +(byte*) char_cursor#0 +(byte*) char_cursor#1 +(byte*) char_cursor#10 +(byte*) char_cursor#11 +(byte*) char_cursor#12 +(byte*) char_cursor#13 +(byte*) char_cursor#14 +(byte*) char_cursor#15 +(byte*) char_cursor#16 +(byte*) char_cursor#17 +(byte*) char_cursor#18 +(byte*) char_cursor#19 +(byte*) char_cursor#2 +(byte*) char_cursor#20 +(byte*) char_cursor#21 +(byte*) char_cursor#22 +(byte*) char_cursor#23 +(byte*) char_cursor#24 +(byte*) char_cursor#25 +(byte*) char_cursor#26 +(byte*) char_cursor#27 +(byte*) char_cursor#28 +(byte*) char_cursor#29 +(byte*) char_cursor#3 +(byte*) char_cursor#30 +(byte*) char_cursor#31 +(byte*) char_cursor#32 +(byte*) char_cursor#33 +(byte*) char_cursor#34 +(byte*) char_cursor#35 +(byte*) char_cursor#36 +(byte*) char_cursor#37 +(byte*) char_cursor#38 +(byte*) char_cursor#39 +(byte*) char_cursor#4 +(byte*) char_cursor#40 +(byte*) char_cursor#41 +(byte*) char_cursor#42 +(byte*) char_cursor#43 +(byte*) char_cursor#44 +(byte*) char_cursor#45 +(byte*) char_cursor#46 +(byte*) char_cursor#47 +(byte*) char_cursor#48 +(byte*) char_cursor#49 +(byte*) char_cursor#5 +(byte*) char_cursor#50 +(byte*) char_cursor#51 +(byte*) char_cursor#52 +(byte*) char_cursor#6 +(byte*) char_cursor#7 +(byte*) char_cursor#8 +(byte*) char_cursor#9 (void()) init_mul_tables() (byte*~) init_mul_tables::$0 (byte*~) init_mul_tables::$1 +(signed byte/signed word~) init_mul_tables::$10 +(byte~) init_mul_tables::$11 +(byte/word~) init_mul_tables::$12 +(boolean~) init_mul_tables::$13 +(boolean~) init_mul_tables::$14 +(byte*~) init_mul_tables::$15 +(boolean~) init_mul_tables::$16 +(byte*~) init_mul_tables::$17 +(byte*~) init_mul_tables::$18 +(byte*~) init_mul_tables::$19 (byte~) init_mul_tables::$2 +(byte*~) init_mul_tables::$20 (boolean~) init_mul_tables::$3 (boolean~) init_mul_tables::$4 (byte~) init_mul_tables::$5 @@ -572,6 +1218,11 @@ SYMBOL TABLE SSA (label) init_mul_tables::@1 (label) init_mul_tables::@2 (label) init_mul_tables::@3 +(label) init_mul_tables::@4 +(label) init_mul_tables::@5 +(label) init_mul_tables::@6 +(label) init_mul_tables::@7 +(label) init_mul_tables::@8 (label) init_mul_tables::@return (byte) init_mul_tables::c (byte) init_mul_tables::c#0 @@ -579,6 +1230,11 @@ SYMBOL TABLE SSA (byte) init_mul_tables::c#2 (byte) init_mul_tables::c#3 (byte) init_mul_tables::c#4 +(byte) init_mul_tables::dir +(byte) init_mul_tables::dir#0 +(byte) init_mul_tables::dir#1 +(byte) init_mul_tables::dir#2 +(byte) init_mul_tables::dir#3 (word) init_mul_tables::sqr (word) init_mul_tables::sqr#0 (word) init_mul_tables::sqr#1 @@ -586,149 +1242,385 @@ SYMBOL TABLE SSA (word) init_mul_tables::sqr#3 (word) init_mul_tables::sqr#4 (word) init_mul_tables::sqr#5 -(byte*) init_mul_tables::sqr_hi -(byte*) init_mul_tables::sqr_hi#0 -(byte*) init_mul_tables::sqr_hi#1 -(byte*) init_mul_tables::sqr_hi#2 -(byte*) init_mul_tables::sqr_hi#3 -(byte*) init_mul_tables::sqr_hi#4 -(byte*) init_mul_tables::sqr_lo -(byte*) init_mul_tables::sqr_lo#0 -(byte*) init_mul_tables::sqr_lo#1 -(byte*) init_mul_tables::sqr_lo#2 -(byte*) init_mul_tables::sqr_lo#3 -(byte*) init_mul_tables::sqr_lo#4 +(byte*) init_mul_tables::sqr1_hi +(byte*) init_mul_tables::sqr1_hi#0 +(byte*) init_mul_tables::sqr1_hi#1 +(byte*) init_mul_tables::sqr1_hi#2 +(byte*) init_mul_tables::sqr1_hi#3 +(byte*) init_mul_tables::sqr1_hi#4 +(byte*) init_mul_tables::sqr1_lo +(byte*) init_mul_tables::sqr1_lo#0 +(byte*) init_mul_tables::sqr1_lo#1 +(byte*) init_mul_tables::sqr1_lo#2 +(byte*) init_mul_tables::sqr1_lo#3 +(byte*) init_mul_tables::sqr1_lo#4 +(byte*) init_mul_tables::sqr2_hi +(byte*) init_mul_tables::sqr2_hi#0 +(byte*) init_mul_tables::sqr2_hi#1 +(byte*) init_mul_tables::sqr2_hi#2 +(byte*) init_mul_tables::sqr2_hi#3 +(byte*) init_mul_tables::sqr2_hi#4 +(byte*) init_mul_tables::sqr2_lo +(byte*) init_mul_tables::sqr2_lo#0 +(byte*) init_mul_tables::sqr2_lo#1 +(byte*) init_mul_tables::sqr2_lo#2 +(byte*) init_mul_tables::sqr2_lo#3 +(byte*) init_mul_tables::sqr2_lo#4 (byte) init_mul_tables::x_2 (byte) init_mul_tables::x_2#0 (byte) init_mul_tables::x_2#1 (byte) init_mul_tables::x_2#2 (byte) init_mul_tables::x_2#3 (byte) init_mul_tables::x_2#4 +(byte) init_mul_tables::x_255 +(byte) init_mul_tables::x_255#0 +(byte) init_mul_tables::x_255#1 +(byte) init_mul_tables::x_255#2 +(byte) init_mul_tables::x_255#3 +(byte) init_mul_tables::x_255#4 (void()) init_mul_tables_asm() (label) init_mul_tables_asm::@return +(byte*) init_mul_tables_asm::mem +(byte*) init_mul_tables_asm::mem#0 +(byte*) line_cursor +(byte*) line_cursor#0 (void()) main() (label) main::@1 (label) main::@2 (label) main::@3 (label) main::@return -(byte[512]) mul_sqr_hi -(byte[512]) mul_sqr_hi#0 -(byte[512]) mul_sqr_lo -(byte[512]) mul_sqr_lo#0 +(byte[512]) mul_sqr1_hi +(byte[512]) mul_sqr1_hi#0 +(byte[512]) mul_sqr1_lo +(byte[512]) mul_sqr1_lo#0 +(byte[512]) mul_sqr2_hi +(byte[512]) mul_sqr2_hi#0 +(byte[512]) mul_sqr2_lo +(byte[512]) mul_sqr2_lo#0 (void()) mul_tables_compare() (boolean~) mul_tables_compare::$0 (boolean~) mul_tables_compare::$1 -(boolean~) mul_tables_compare::$10 +(byte*~) mul_tables_compare::$10 (boolean~) mul_tables_compare::$11 -(boolean~) mul_tables_compare::$12 -(byte*~) mul_tables_compare::$2 -(byte*~) mul_tables_compare::$3 -(boolean~) mul_tables_compare::$4 -(boolean~) mul_tables_compare::$5 -(boolean~) mul_tables_compare::$6 -(boolean~) mul_tables_compare::$7 -(byte*~) mul_tables_compare::$8 -(byte*~) mul_tables_compare::$9 +(word~) mul_tables_compare::$4 +(word~) mul_tables_compare::$7 +(word/signed word~) mul_tables_compare::$9 (label) mul_tables_compare::@1 +(label) mul_tables_compare::@10 (label) mul_tables_compare::@2 (label) mul_tables_compare::@3 -(label) mul_tables_compare::@4 -(label) mul_tables_compare::@5 (label) mul_tables_compare::@6 (label) mul_tables_compare::@7 (label) mul_tables_compare::@8 (label) mul_tables_compare::@9 (label) mul_tables_compare::@return -(byte) mul_tables_compare::i -(byte) mul_tables_compare::i#0 -(byte) mul_tables_compare::i#1 -(byte) mul_tables_compare::i#10 -(byte) mul_tables_compare::i#2 -(byte) mul_tables_compare::i#3 -(byte) mul_tables_compare::i#4 -(byte) mul_tables_compare::i#5 -(byte) mul_tables_compare::i#6 -(byte) mul_tables_compare::i#7 -(byte) mul_tables_compare::i#8 -(byte) mul_tables_compare::i#9 +(byte*) mul_tables_compare::asm_sqr +(byte*) mul_tables_compare::asm_sqr#0 +(byte*) mul_tables_compare::asm_sqr#1 +(byte*) mul_tables_compare::asm_sqr#2 +(byte*) mul_tables_compare::asm_sqr#3 +(byte*) mul_tables_compare::asm_sqr#4 +(byte*) mul_tables_compare::asm_sqr#5 +(byte*) mul_tables_compare::asm_sqr#6 +(byte*) mul_tables_compare::kc_sqr +(byte*) mul_tables_compare::kc_sqr#0 +(byte*) mul_tables_compare::kc_sqr#1 +(byte*) mul_tables_compare::kc_sqr#2 +(byte*) mul_tables_compare::kc_sqr#3 +(byte*) mul_tables_compare::kc_sqr#4 +(byte*) mul_tables_compare::kc_sqr#5 +(byte*) mul_tables_compare::kc_sqr#6 +(byte*) mul_tables_compare::kc_sqr#7 +(byte*) mul_tables_compare::kc_sqr#8 +(const string) mul_tables_compare::str = (string) "mul table mismatch at @" +(const string) mul_tables_compare::str1 = (string) " / @" +(void()) print_byte((byte) print_byte::b) +(byte~) print_byte::$0 +(byte~) print_byte::$2 +(label) print_byte::@1 +(label) print_byte::@2 +(label) print_byte::@return +(byte) print_byte::b +(byte) print_byte::b#0 +(byte) print_byte::b#1 +(byte) print_byte::b#2 +(byte) print_byte::b#3 +(byte[]) print_byte::hextab +(byte[]) print_byte::hextab#0 +(void()) print_char((byte) print_char::ch) +(label) print_char::@return +(byte) print_char::ch +(byte) print_char::ch#0 +(byte) print_char::ch#1 +(byte) print_char::ch#2 +(void()) print_cls() +(word/signed word~) print_cls::$0 +(boolean~) print_cls::$1 +(label) print_cls::@1 +(label) print_cls::@return +(byte*) print_cls::sc +(byte*) print_cls::sc#0 +(byte*) print_cls::sc#1 +(byte*) print_cls::sc#2 +(void()) print_str((byte*) print_str::str) +(boolean~) print_str::$0 +(label) print_str::@1 +(label) print_str::@2 +(label) print_str::@return +(byte*) print_str::str +(byte*) print_str::str#0 +(byte*) print_str::str#1 +(byte*) print_str::str#2 +(byte*) print_str::str#3 +(byte*) print_str::str#4 +(byte*) print_str::str#5 +(void()) print_word((word) print_word::w) +(byte~) print_word::$0 +(byte~) print_word::$2 +(label) print_word::@1 +(label) print_word::@2 +(label) print_word::@return +(word) print_word::w +(word) print_word::w#0 +(word) print_word::w#1 +(word) print_word::w#2 +(word) print_word::w#3 OPTIMIZING CONTROL FLOW GRAPH -Culled Empty Block (label) main::@3 -Culled Empty Block (label) @5 -Succesful SSA optimization Pass2CullEmptyBlocks Inversing boolean not (boolean~) init_mul_tables::$4 ← (byte~) init_mul_tables::$2 != (byte/signed byte/word/signed word) 0 from (boolean~) init_mul_tables::$3 ← (byte~) init_mul_tables::$2 == (byte/signed byte/word/signed word) 0 -Inversing boolean not (boolean~) mul_tables_compare::$1 ← *((byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#2) == *((byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#2) from (boolean~) mul_tables_compare::$0 ← *((byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#2) != *((byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#2) -Inversing boolean not (boolean~) mul_tables_compare::$5 ← *((byte*~) mul_tables_compare::$2 + (byte) mul_tables_compare::i#3) == *((byte*~) mul_tables_compare::$3 + (byte) mul_tables_compare::i#3) from (boolean~) mul_tables_compare::$4 ← *((byte*~) mul_tables_compare::$2 + (byte) mul_tables_compare::i#3) != *((byte*~) mul_tables_compare::$3 + (byte) mul_tables_compare::i#3) -Inversing boolean not (boolean~) mul_tables_compare::$7 ← *((byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#4) == *((byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#4) from (boolean~) mul_tables_compare::$6 ← *((byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#4) != *((byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#4) -Inversing boolean not (boolean~) mul_tables_compare::$11 ← *((byte*~) mul_tables_compare::$8 + (byte) mul_tables_compare::i#5) == *((byte*~) mul_tables_compare::$9 + (byte) mul_tables_compare::i#5) from (boolean~) mul_tables_compare::$10 ← *((byte*~) mul_tables_compare::$8 + (byte) mul_tables_compare::i#5) != *((byte*~) mul_tables_compare::$9 + (byte) mul_tables_compare::i#5) +Inversing boolean not (boolean~) init_mul_tables::$14 ← (byte) init_mul_tables::x_255#1 != (byte/signed byte/word/signed word) 0 from (boolean~) init_mul_tables::$13 ← (byte) init_mul_tables::x_255#1 == (byte/signed byte/word/signed word) 0 +Inversing boolean not (boolean~) mul_tables_compare::$1 ← *((byte*) mul_tables_compare::kc_sqr#2) == *((byte*) mul_tables_compare::asm_sqr#2) from (boolean~) mul_tables_compare::$0 ← *((byte*) mul_tables_compare::kc_sqr#2) != *((byte*) mul_tables_compare::asm_sqr#2) Succesful SSA optimization Pass2UnaryNotSimplification -Not aliassing across scopes: BGCOL#13 BGCOL#14 -Not aliassing across scopes: BGCOL#1 BGCOL#6 -Alias (byte*) BGCOL#11 = (byte*) BGCOL#13 (byte*) BGCOL#6 -Alias (byte*) BGCOL#0 = (byte*) BGCOL#16 (byte*) BGCOL#15 (byte*) BGCOL#14 -Alias (byte*) init_mul_tables::sqr_hi#0 = (byte*~) init_mul_tables::$0 -Alias (byte*) init_mul_tables::sqr_lo#0 = (byte*~) init_mul_tables::$1 +Not aliassing across scopes: print_str::str#5 print_str::str#1 +Not aliassing across scopes: char_cursor#44 char_cursor#41 +Not aliassing across scopes: print_word::w#2 print_word::w#0 +Not aliassing across scopes: char_cursor#38 char_cursor#13 +Not aliassing across scopes: char_cursor#21 char_cursor#8 +Not aliassing across scopes: char_cursor#22 char_cursor#8 +Not aliassing across scopes: print_byte::b#2 print_byte::b#0 +Not aliassing across scopes: char_cursor#39 char_cursor#38 +Not aliassing across scopes: char_cursor#24 char_cursor#10 +Not aliassing across scopes: char_cursor#25 char_cursor#10 +Not aliassing across scopes: print_char::ch#2 print_char::ch#0 +Not aliassing across scopes: char_cursor#27 char_cursor#39 +Not aliassing across scopes: char_cursor#49 char_cursor#43 +Not aliassing across scopes: BGCOL#7 BGCOL#8 +Not aliassing across scopes: char_cursor#29 char_cursor#17 +Not aliassing across scopes: init_mul_tables::sqr2_hi#0 mul_sqr2_hi#0 +Not aliassing across scopes: init_mul_tables::sqr2_lo#0 mul_sqr2_lo#0 +Not aliassing across scopes: BGCOL#1 BGCOL#3 +Not aliassing across scopes: char_cursor#51 char_cursor#40 +Not aliassing across scopes: mul_tables_compare::asm_sqr#0 asm_mul_sqr1_lo#0 +Not aliassing across scopes: mul_tables_compare::kc_sqr#0 mul_sqr1_lo#0 +Not aliassing across scopes: char_cursor#31 char_cursor#2 +Not aliassing across scopes: char_cursor#32 char_cursor#5 +Not aliassing across scopes: char_cursor#33 char_cursor#2 +Not aliassing across scopes: char_cursor#34 char_cursor#5 +Not aliassing across scopes: char_cursor#36 char_cursor#12 +Alias (byte*) char_cursor#0 = (byte*) line_cursor#0 (byte*) char_cursor#52 (byte*) char_cursor#50 (byte*) char_cursor#48 (byte*) char_cursor#43 +Alias (byte*) print_str::str#3 = (byte*) print_str::str#4 +Alias (byte*) char_cursor#19 = (byte*) char_cursor#37 (byte*) char_cursor#20 (byte*) char_cursor#2 +Alias (byte) print_byte::b#0 = (byte~) print_word::$0 +Alias (word) print_word::w#2 = (word) print_word::w#3 +Alias (byte*) char_cursor#21 = (byte*) char_cursor#3 +Alias (byte) print_byte::b#1 = (byte~) print_word::$2 +Alias (byte*) char_cursor#22 = (byte*) char_cursor#4 (byte*) char_cursor#23 (byte*) char_cursor#5 +Alias (byte) print_byte::b#2 = (byte) print_byte::b#3 +Alias (byte*) char_cursor#24 = (byte*) char_cursor#6 +Alias (byte*) char_cursor#25 = (byte*) char_cursor#7 (byte*) char_cursor#26 (byte*) char_cursor#8 +Alias (byte*) char_cursor#10 = (byte*) char_cursor#28 (byte*) char_cursor#9 +Alias (byte*) char_cursor#40 = (byte*) char_cursor#45 (byte*) char_cursor#49 +Alias (byte*) BGCOL#3 = (byte*) BGCOL#5 (byte*) BGCOL#7 +Alias (byte*) char_cursor#11 = (byte*) char_cursor#29 (byte*) char_cursor#30 (byte*) char_cursor#12 +Alias (byte*) BGCOL#0 = (byte*) BGCOL#10 (byte*) BGCOL#9 (byte*) BGCOL#8 +Alias (byte*) init_mul_tables::sqr1_hi#0 = (byte*~) init_mul_tables::$0 +Alias (byte*) init_mul_tables::sqr1_lo#0 = (byte*~) init_mul_tables::$1 Alias (word) init_mul_tables::sqr#1 = (word~) init_mul_tables::$7 Alias (byte) init_mul_tables::x_2#3 = (byte) init_mul_tables::x_2#4 Alias (word) init_mul_tables::sqr#4 = (word) init_mul_tables::sqr#5 -Alias (byte*) init_mul_tables::sqr_lo#3 = (byte*) init_mul_tables::sqr_lo#4 -Alias (byte*) init_mul_tables::sqr_hi#3 = (byte*) init_mul_tables::sqr_hi#4 +Alias (byte*) init_mul_tables::sqr1_lo#3 = (byte*) init_mul_tables::sqr1_lo#4 +Alias (byte*) init_mul_tables::sqr1_hi#3 = (byte*) init_mul_tables::sqr1_hi#4 Alias (byte) init_mul_tables::c#1 = (byte) init_mul_tables::c#4 -Alias (byte*) BGCOL#2 = (byte*) BGCOL#7 -Alias (byte) mul_tables_compare::i#2 = (byte) mul_tables_compare::i#7 -Alias (byte*) BGCOL#3 = (byte*) BGCOL#8 -Alias (byte) mul_tables_compare::i#3 = (byte) mul_tables_compare::i#8 -Alias (byte*) BGCOL#4 = (byte*) BGCOL#9 -Alias (byte) mul_tables_compare::i#4 = (byte) mul_tables_compare::i#9 -Alias (byte*) BGCOL#10 = (byte*) BGCOL#5 -Alias (byte) mul_tables_compare::i#10 = (byte) mul_tables_compare::i#5 +Alias (byte) init_mul_tables::x_255#0 = (byte~) init_mul_tables::$11 +Alias (byte) init_mul_tables::x_255#1 = (byte/word~) init_mul_tables::$12 (byte) init_mul_tables::x_255#4 +Alias (byte*) init_mul_tables::sqr2_lo#2 = (byte*) init_mul_tables::sqr2_lo#4 +Alias (byte*) init_mul_tables::sqr2_hi#1 = (byte*) init_mul_tables::sqr2_hi#4 +Alias (byte*) mul_tables_compare::asm_sqr#2 = (byte*) mul_tables_compare::asm_sqr#3 (byte*) mul_tables_compare::asm_sqr#6 (byte*) mul_tables_compare::asm_sqr#5 (byte*) mul_tables_compare::asm_sqr#4 +Alias (byte*) mul_tables_compare::kc_sqr#2 = (byte*) mul_tables_compare::kc_sqr#3 (byte*) mul_tables_compare::kc_sqr#8 (byte*) mul_tables_compare::kc_sqr#7 (byte*) mul_tables_compare::kc_sqr#6 (byte*) mul_tables_compare::kc_sqr#5 (byte*) mul_tables_compare::kc_sqr#4 +Alias (byte*) char_cursor#41 = (byte*) char_cursor#42 (byte*) char_cursor#46 (byte*) char_cursor#47 +Alias (byte*) BGCOL#2 = (byte*) BGCOL#6 (byte*) BGCOL#4 +Alias (byte*) char_cursor#13 = (byte*) char_cursor#31 +Alias (word) print_word::w#0 = (word~) mul_tables_compare::$4 +Alias (byte*) char_cursor#14 = (byte*) char_cursor#32 +Alias (byte*) char_cursor#15 = (byte*) char_cursor#33 +Alias (word) print_word::w#1 = (word~) mul_tables_compare::$7 +Alias (byte*) char_cursor#16 = (byte*) char_cursor#34 +Alias (byte*) char_cursor#17 = (byte*) char_cursor#35 +Alias (byte*) char_cursor#18 = (byte*) char_cursor#36 Succesful SSA optimization Pass2AliasElimination -Not aliassing across scopes: BGCOL#11 BGCOL#0 -Not aliassing across scopes: BGCOL#1 BGCOL#11 -Alias (byte*) init_mul_tables::sqr_lo#2 = (byte*) init_mul_tables::sqr_lo#3 -Alias (byte*) init_mul_tables::sqr_hi#2 = (byte*) init_mul_tables::sqr_hi#3 +Not aliassing across scopes: print_str::str#5 print_str::str#1 +Not aliassing across scopes: char_cursor#44 char_cursor#41 +Not aliassing across scopes: print_word::w#2 print_word::w#0 +Not aliassing across scopes: char_cursor#38 char_cursor#13 +Not aliassing across scopes: char_cursor#21 char_cursor#25 +Not aliassing across scopes: char_cursor#22 char_cursor#25 +Not aliassing across scopes: print_byte::b#2 print_byte::b#0 +Not aliassing across scopes: char_cursor#39 char_cursor#38 +Not aliassing across scopes: char_cursor#24 char_cursor#10 +Not aliassing across scopes: char_cursor#25 char_cursor#10 +Not aliassing across scopes: print_char::ch#2 print_char::ch#0 +Not aliassing across scopes: char_cursor#27 char_cursor#39 +Not aliassing across scopes: char_cursor#40 char_cursor#0 +Not aliassing across scopes: BGCOL#3 BGCOL#0 +Not aliassing across scopes: char_cursor#11 char_cursor#17 +Not aliassing across scopes: init_mul_tables::sqr2_hi#0 mul_sqr2_hi#0 +Not aliassing across scopes: init_mul_tables::sqr2_lo#0 mul_sqr2_lo#0 +Not aliassing across scopes: BGCOL#1 BGCOL#3 +Not aliassing across scopes: char_cursor#51 char_cursor#40 +Not aliassing across scopes: mul_tables_compare::asm_sqr#0 asm_mul_sqr1_lo#0 +Not aliassing across scopes: mul_tables_compare::kc_sqr#0 mul_sqr1_lo#0 +Not aliassing across scopes: char_cursor#13 char_cursor#19 +Not aliassing across scopes: char_cursor#14 char_cursor#22 +Not aliassing across scopes: char_cursor#15 char_cursor#19 +Not aliassing across scopes: char_cursor#16 char_cursor#22 +Not aliassing across scopes: char_cursor#18 char_cursor#11 +Alias (byte*) init_mul_tables::sqr1_lo#2 = (byte*) init_mul_tables::sqr1_lo#3 +Alias (byte*) init_mul_tables::sqr1_hi#2 = (byte*) init_mul_tables::sqr1_hi#3 Alias (byte) init_mul_tables::c#1 = (byte) init_mul_tables::c#3 -Alias (byte) mul_tables_compare::i#10 = (byte) mul_tables_compare::i#3 (byte) mul_tables_compare::i#2 (byte) mul_tables_compare::i#4 (byte) mul_tables_compare::i#6 -Alias (byte*) BGCOL#10 = (byte*) BGCOL#3 (byte*) BGCOL#2 (byte*) BGCOL#4 (byte*) BGCOL#12 +Alias (byte*) init_mul_tables::sqr2_lo#2 = (byte*) init_mul_tables::sqr2_lo#3 +Alias (byte) init_mul_tables::x_255#1 = (byte) init_mul_tables::x_255#3 +Alias (byte*) init_mul_tables::sqr2_hi#1 = (byte*) init_mul_tables::sqr2_hi#3 Succesful SSA optimization Pass2AliasElimination -Not aliassing across scopes: BGCOL#11 BGCOL#0 -Not aliassing across scopes: BGCOL#1 BGCOL#11 -Self Phi Eliminated (byte*) BGCOL#10 +Not aliassing across scopes: print_str::str#5 print_str::str#1 +Not aliassing across scopes: char_cursor#44 char_cursor#41 +Not aliassing across scopes: print_word::w#2 print_word::w#0 +Not aliassing across scopes: char_cursor#38 char_cursor#13 +Not aliassing across scopes: char_cursor#21 char_cursor#25 +Not aliassing across scopes: char_cursor#22 char_cursor#25 +Not aliassing across scopes: print_byte::b#2 print_byte::b#0 +Not aliassing across scopes: char_cursor#39 char_cursor#38 +Not aliassing across scopes: char_cursor#24 char_cursor#10 +Not aliassing across scopes: char_cursor#25 char_cursor#10 +Not aliassing across scopes: print_char::ch#2 print_char::ch#0 +Not aliassing across scopes: char_cursor#27 char_cursor#39 +Not aliassing across scopes: char_cursor#40 char_cursor#0 +Not aliassing across scopes: BGCOL#3 BGCOL#0 +Not aliassing across scopes: char_cursor#11 char_cursor#17 +Not aliassing across scopes: init_mul_tables::sqr2_hi#0 mul_sqr2_hi#0 +Not aliassing across scopes: init_mul_tables::sqr2_lo#0 mul_sqr2_lo#0 +Not aliassing across scopes: BGCOL#1 BGCOL#3 +Not aliassing across scopes: char_cursor#51 char_cursor#40 +Not aliassing across scopes: mul_tables_compare::asm_sqr#0 asm_mul_sqr1_lo#0 +Not aliassing across scopes: mul_tables_compare::kc_sqr#0 mul_sqr1_lo#0 +Not aliassing across scopes: char_cursor#13 char_cursor#19 +Not aliassing across scopes: char_cursor#14 char_cursor#22 +Not aliassing across scopes: char_cursor#15 char_cursor#19 +Not aliassing across scopes: char_cursor#16 char_cursor#22 +Not aliassing across scopes: char_cursor#18 char_cursor#11 +Self Phi Eliminated (byte*) BGCOL#2 +Self Phi Eliminated (byte*) char_cursor#41 Succesful SSA optimization Pass2SelfPhiElimination -Redundant Phi (byte*) BGCOL#11 (byte*) BGCOL#0 -Redundant Phi (byte*) BGCOL#1 (byte*) BGCOL#11 -Redundant Phi (byte*) BGCOL#10 (byte*) BGCOL#1 +Redundant Phi (byte*) char_cursor#21 (byte*) char_cursor#25 +Redundant Phi (byte*) char_cursor#22 (byte*) char_cursor#25 +Redundant Phi (byte*) char_cursor#24 (byte*) char_cursor#10 +Redundant Phi (byte*) char_cursor#25 (byte*) char_cursor#10 +Redundant Phi (byte*) char_cursor#40 (byte*) char_cursor#0 +Redundant Phi (byte*) BGCOL#3 (byte*) BGCOL#0 +Redundant Phi (byte*) char_cursor#11 (byte*) char_cursor#17 +Redundant Phi (byte*) BGCOL#1 (byte*) BGCOL#3 +Redundant Phi (byte*) char_cursor#51 (byte*) char_cursor#40 +Redundant Phi (byte*) BGCOL#2 (byte*) BGCOL#1 +Redundant Phi (byte*) char_cursor#41 (byte*) char_cursor#51 +Redundant Phi (byte*) char_cursor#13 (byte*) char_cursor#19 +Redundant Phi (byte*) char_cursor#14 (byte*) char_cursor#22 +Redundant Phi (byte*) char_cursor#15 (byte*) char_cursor#19 +Redundant Phi (byte*) char_cursor#16 (byte*) char_cursor#22 +Redundant Phi (byte*) char_cursor#18 (byte*) char_cursor#11 Succesful SSA optimization Pass2RedundantPhiElimination +Redundant Phi (byte*) char_cursor#38 (byte*) char_cursor#19 +Succesful SSA optimization Pass2RedundantPhiElimination +Simple Condition (boolean~) print_str::$0 if(*((byte*) print_str::str#3)!=(byte) '@') goto print_str::@2 +Simple Condition (boolean~) print_cls::$1 if((byte*) print_cls::sc#1!=(word/signed word~) print_cls::$0) goto print_cls::@1 Simple Condition (boolean~) init_mul_tables::$4 if((byte~) init_mul_tables::$2!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@2 -Simple Condition (boolean~) init_mul_tables::$9 if((byte*) init_mul_tables::sqr_lo#1!=(byte*~) init_mul_tables::$8) goto init_mul_tables::@1 -Simple Condition (boolean~) mul_tables_compare::$1 if(*((byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@2 -Simple Condition (boolean~) mul_tables_compare::$5 if(*((byte*~) mul_tables_compare::$2 + (byte) mul_tables_compare::i#10)==*((byte*~) mul_tables_compare::$3 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@3 -Simple Condition (boolean~) mul_tables_compare::$7 if(*((byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@4 -Simple Condition (boolean~) mul_tables_compare::$11 if(*((byte*~) mul_tables_compare::$8 + (byte) mul_tables_compare::i#10)==*((byte*~) mul_tables_compare::$9 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@5 -Simple Condition (boolean~) mul_tables_compare::$12 if((byte) mul_tables_compare::i#1!=(byte/signed byte/word/signed word) 0) goto mul_tables_compare::@1 +Simple Condition (boolean~) init_mul_tables::$9 if((byte*) init_mul_tables::sqr1_lo#1!=(byte*~) init_mul_tables::$8) goto init_mul_tables::@1 +Simple Condition (boolean~) init_mul_tables::$14 if((byte) init_mul_tables::x_255#1!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@4 +Simple Condition (boolean~) init_mul_tables::$16 if((byte*) init_mul_tables::sqr2_lo#1!=(byte*~) init_mul_tables::$15) goto init_mul_tables::@3 +Simple Condition (boolean~) mul_tables_compare::$1 if(*((byte*) mul_tables_compare::kc_sqr#2)==*((byte*) mul_tables_compare::asm_sqr#2)) goto mul_tables_compare::@2 +Simple Condition (boolean~) mul_tables_compare::$11 if((byte*) mul_tables_compare::kc_sqr#1<(byte*~) mul_tables_compare::$10) goto mul_tables_compare::@1 Succesful SSA optimization Pass2ConditionalJumpSimplification +Constant (const byte*) char_cursor#0 = ((byte*))1024 +Constant (const byte[]) print_byte::hextab#0 = { '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f' } +Constant (const byte*) print_cls::sc#0 = ((byte*))1024 +Constant (const word/signed word) print_cls::$0 = 1024+1000 Constant (const byte*) BGCOL#0 = ((byte*))53281 -Constant (const byte[512]) mul_sqr_lo#0 = { fill( 512, 0) } -Constant (const byte[512]) mul_sqr_hi#0 = { fill( 512, 0) } +Constant (const byte[512]) mul_sqr1_lo#0 = { fill( 512, 0) } +Constant (const byte[512]) mul_sqr1_hi#0 = { fill( 512, 0) } +Constant (const byte[512]) mul_sqr2_lo#0 = { fill( 512, 0) } +Constant (const byte[512]) mul_sqr2_hi#0 = { fill( 512, 0) } Constant (const word) init_mul_tables::sqr#0 = 0 Constant (const byte) init_mul_tables::x_2#0 = 0 Constant (const byte) init_mul_tables::c#0 = 0 -Constant (const byte[512]) asm_mul_sqr_lo#0 = { fill( 512, 0) } -Constant (const byte[512]) asm_mul_sqr_hi#0 = { fill( 512, 0) } -Constant (const byte) mul_tables_compare::i#0 = 0 +Constant (const signed byte/signed word) init_mul_tables::$10 = -1 +Constant (const byte) init_mul_tables::dir#0 = 255 +Constant (const byte) init_mul_tables::dir#1 = 1 +Constant (const byte[512]) asm_mul_sqr1_lo#0 = { fill( 512, 0) } +Constant (const byte[512]) asm_mul_sqr1_hi#0 = { fill( 512, 0) } +Constant (const byte[512]) asm_mul_sqr2_lo#0 = { fill( 512, 0) } +Constant (const byte[512]) asm_mul_sqr2_hi#0 = { fill( 512, 0) } +Constant (const byte*) init_mul_tables_asm::mem#0 = ((byte*))255 +Constant (const word/signed word) mul_tables_compare::$9 = 512*4 +Constant (const string) print_str::str#1 = mul_tables_compare::str +Constant (const string) print_str::str#2 = mul_tables_compare::str1 Succesful SSA optimization Pass2ConstantIdentification -Constant (const byte*) init_mul_tables::sqr_hi#0 = mul_sqr_hi#0+1 -Constant (const byte*) init_mul_tables::sqr_lo#0 = mul_sqr_lo#0+1 -Constant (const byte*) init_mul_tables::$8 = mul_sqr_lo#0+512 -Constant (const byte*) mul_tables_compare::$2 = mul_sqr_hi#0+256 -Constant (const byte*) mul_tables_compare::$3 = asm_mul_sqr_hi#0+256 -Constant (const byte*) mul_tables_compare::$8 = mul_sqr_hi#0+256 -Constant (const byte*) mul_tables_compare::$9 = asm_mul_sqr_hi#0+256 +Constant (const byte*) init_mul_tables::sqr1_hi#0 = mul_sqr1_hi#0+1 +Constant (const byte*) init_mul_tables::sqr1_lo#0 = mul_sqr1_lo#0+1 +Constant (const byte*) init_mul_tables::$8 = mul_sqr1_lo#0+512 +Constant (const byte) init_mul_tables::x_255#0 = ((byte))init_mul_tables::$10 +Constant (const byte[512]) init_mul_tables::sqr2_hi#0 = mul_sqr2_hi#0 +Constant (const byte[512]) init_mul_tables::sqr2_lo#0 = mul_sqr2_lo#0 +Constant (const byte*) init_mul_tables::$15 = mul_sqr2_lo#0+511 +Constant (const byte*) init_mul_tables::$17 = mul_sqr2_lo#0+511 +Constant (const byte*) init_mul_tables::$18 = mul_sqr1_lo#0+256 +Constant (const byte*) init_mul_tables::$19 = mul_sqr2_hi#0+511 +Constant (const byte*) init_mul_tables::$20 = mul_sqr1_hi#0+256 +Constant (const byte[512]) mul_tables_compare::asm_sqr#0 = asm_mul_sqr1_lo#0 +Constant (const byte[512]) mul_tables_compare::kc_sqr#0 = mul_sqr1_lo#0 +Constant (const byte*) mul_tables_compare::$10 = mul_sqr1_lo#0+mul_tables_compare::$9 Succesful SSA optimization Pass2ConstantIdentification -Culled Empty Block (label) @1 -Culled Empty Block (label) @2 +Culled Empty Block (label) print_word::@2 +Culled Empty Block (label) print_byte::@2 +Culled Empty Block (label) @6 +Culled Empty Block (label) main::@3 +Culled Empty Block (label) @7 +Culled Empty Block (label) init_mul_tables::@6 +Not culling empty block because it shares successor with its predecessor. (label) init_mul_tables::@7 +Culled Empty Block (label) @8 +Culled Empty Block (label) mul_tables_compare::@10 +Culled Empty Block (label) @11 Succesful SSA optimization Pass2CullEmptyBlocks +Not culling empty block because it shares successor with its predecessor. (label) init_mul_tables::@7 +Not aliassing across scopes: print_word::w#2 print_word::w#0 +Not aliassing across scopes: print_byte::b#2 print_byte::b#0 +Not aliassing across scopes: char_cursor#39 char_cursor#19 +Not aliassing across scopes: print_char::ch#2 print_char::ch#0 +Not aliassing across scopes: char_cursor#27 char_cursor#39 +Not aliassing across scopes: char_cursor#17 char_cursor#10 +Not culling empty block because it shares successor with its predecessor. (label) init_mul_tables::@7 +Not aliassing across scopes: print_word::w#2 print_word::w#0 +Not aliassing across scopes: print_byte::b#2 print_byte::b#0 +Not aliassing across scopes: char_cursor#39 char_cursor#19 +Not aliassing across scopes: print_char::ch#2 print_char::ch#0 +Not aliassing across scopes: char_cursor#27 char_cursor#39 +Not aliassing across scopes: char_cursor#17 char_cursor#10 OPTIMIZING CONTROL FLOW GRAPH +Inlining constant with var siblings (const string) print_str::str#1 +Inlining constant with var siblings (const string) print_str::str#1 +Inlining constant with var siblings (const string) print_str::str#1 +Inlining constant with var siblings (const string) print_str::str#2 +Inlining constant with var siblings (const string) print_str::str#2 +Inlining constant with var siblings (const string) print_str::str#2 +Inlining constant with var siblings (const byte*) print_cls::sc#0 +Inlining constant with var siblings (const byte*) print_cls::sc#0 Inlining constant with var siblings (const word) init_mul_tables::sqr#0 Inlining constant with var siblings (const word) init_mul_tables::sqr#0 Inlining constant with var siblings (const word) init_mul_tables::sqr#0 @@ -738,39 +1630,84 @@ Inlining constant with var siblings (const byte) init_mul_tables::x_2#0 Inlining constant with var siblings (const byte) init_mul_tables::x_2#0 Inlining constant with var siblings (const byte) init_mul_tables::c#0 Inlining constant with var siblings (const byte) init_mul_tables::c#0 -Inlining constant with var siblings (const byte*) init_mul_tables::sqr_hi#0 -Inlining constant with var siblings (const byte*) init_mul_tables::sqr_hi#0 -Inlining constant with var siblings (const byte*) init_mul_tables::sqr_lo#0 -Inlining constant with var siblings (const byte*) init_mul_tables::sqr_lo#0 -Inlining constant with var siblings (const byte) mul_tables_compare::i#0 -Inlining constant with var siblings (const byte) mul_tables_compare::i#0 -Constant inlined mul_tables_compare::i#0 = (byte/signed byte/word/signed word) 0 -Constant inlined init_mul_tables::sqr_lo#0 = (const byte[512]) mul_sqr_lo#0+(byte/signed byte/word/signed word) 1 -Constant inlined init_mul_tables::sqr#0 = (byte/signed byte/word/signed word) 0 -Constant inlined mul_tables_compare::$3 = (const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 -Constant inlined mul_tables_compare::$2 = (const byte[512]) mul_sqr_hi#0+(word/signed word) 256 -Constant inlined init_mul_tables::$8 = (const byte[512]) mul_sqr_lo#0+(word/signed word) 512 +Inlining constant with var siblings (const byte) init_mul_tables::dir#0 +Inlining constant with var siblings (const byte) init_mul_tables::dir#0 +Inlining constant with different constant siblings (const byte) init_mul_tables::dir#0 +Inlining constant with var siblings (const byte) init_mul_tables::dir#1 +Inlining constant with var siblings (const byte) init_mul_tables::dir#1 +Inlining constant with different constant siblings (const byte) init_mul_tables::dir#1 +Inlining constant with var siblings (const byte*) init_mul_tables::sqr1_hi#0 +Inlining constant with var siblings (const byte*) init_mul_tables::sqr1_hi#0 +Inlining constant with var siblings (const byte*) init_mul_tables::sqr1_lo#0 +Inlining constant with var siblings (const byte*) init_mul_tables::sqr1_lo#0 +Inlining constant with var siblings (const byte) init_mul_tables::x_255#0 +Inlining constant with var siblings (const byte) init_mul_tables::x_255#0 +Inlining constant with var siblings (const byte[512]) init_mul_tables::sqr2_hi#0 +Inlining constant with var siblings (const byte[512]) init_mul_tables::sqr2_hi#0 +Inlining constant with var siblings (const byte[512]) init_mul_tables::sqr2_lo#0 +Inlining constant with var siblings (const byte[512]) init_mul_tables::sqr2_lo#0 +Inlining constant with var siblings (const byte[512]) mul_tables_compare::asm_sqr#0 +Inlining constant with var siblings (const byte[512]) mul_tables_compare::asm_sqr#0 +Inlining constant with var siblings (const byte[512]) mul_tables_compare::kc_sqr#0 +Inlining constant with var siblings (const byte[512]) mul_tables_compare::kc_sqr#0 +Inlining constant with var siblings (const byte*) char_cursor#0 +Inlining constant with var siblings (const byte*) char_cursor#0 +Inlining constant with var siblings (const byte*) char_cursor#0 +Inlining constant with var siblings (const byte*) char_cursor#0 +Inlining constant with var siblings (const byte*) char_cursor#0 +Inlining constant with var siblings (const byte*) char_cursor#0 +Inlining constant with var siblings (const byte*) char_cursor#0 +Constant inlined print_cls::$0 = (word/signed word) 1024+(word/signed word) 1000 Constant inlined init_mul_tables::x_2#0 = (byte/signed byte/word/signed word) 0 +Constant inlined init_mul_tables::sqr1_hi#0 = (const byte[512]) mul_sqr1_hi#0+(byte/signed byte/word/signed word) 1 +Constant inlined init_mul_tables::$15 = (const byte[512]) mul_sqr2_lo#0+(word/signed word) 511 +Constant inlined init_mul_tables::dir#0 = (byte/word/signed word) 255 +Constant inlined init_mul_tables::sqr1_lo#0 = (const byte[512]) mul_sqr1_lo#0+(byte/signed byte/word/signed word) 1 +Constant inlined init_mul_tables::$17 = (const byte[512]) mul_sqr2_lo#0+(word/signed word) 511 +Constant inlined init_mul_tables::$18 = (const byte[512]) mul_sqr1_lo#0+(word/signed word) 256 +Constant inlined init_mul_tables::$19 = (const byte[512]) mul_sqr2_hi#0+(word/signed word) 511 +Constant inlined init_mul_tables::x_255#0 = ((byte))-(byte/signed byte/word/signed word) 1 +Constant inlined init_mul_tables::$8 = (const byte[512]) mul_sqr1_lo#0+(word/signed word) 512 +Constant inlined init_mul_tables::dir#1 = (byte/signed byte/word/signed word) 1 +Constant inlined mul_tables_compare::$9 = (word/signed word) 512*(byte/signed byte/word/signed word) 4 +Constant inlined init_mul_tables::$10 = -(byte/signed byte/word/signed word) 1 +Constant inlined mul_tables_compare::$10 = (const byte[512]) mul_sqr1_lo#0+(word/signed word) 512*(byte/signed byte/word/signed word) 4 +Constant inlined init_mul_tables::sqr#0 = (byte/signed byte/word/signed word) 0 +Constant inlined init_mul_tables::sqr2_hi#0 = (const byte[512]) mul_sqr2_hi#0 +Constant inlined init_mul_tables::sqr2_lo#0 = (const byte[512]) mul_sqr2_lo#0 Constant inlined init_mul_tables::c#0 = (byte/signed byte/word/signed word) 0 -Constant inlined mul_tables_compare::$9 = (const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 -Constant inlined mul_tables_compare::$8 = (const byte[512]) mul_sqr_hi#0+(word/signed word) 256 -Constant inlined init_mul_tables::sqr_hi#0 = (const byte[512]) mul_sqr_hi#0+(byte/signed byte/word/signed word) 1 +Constant inlined print_cls::sc#0 = ((byte*))(word/signed word) 1024 +Constant inlined mul_tables_compare::kc_sqr#0 = (const byte[512]) mul_sqr1_lo#0 +Constant inlined print_str::str#2 = (const string) mul_tables_compare::str1 +Constant inlined char_cursor#0 = ((byte*))(word/signed word) 1024 +Constant inlined init_mul_tables::$20 = (const byte[512]) mul_sqr1_hi#0+(word/signed word) 256 +Constant inlined print_str::str#1 = (const string) mul_tables_compare::str +Constant inlined mul_tables_compare::asm_sqr#0 = (const byte[512]) asm_mul_sqr1_lo#0 Succesful SSA optimization Pass2ConstantInlining -Block Sequence Planned @begin @4 @end main main::@1 main::@2 main::@return mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@6 mul_tables_compare::@2 mul_tables_compare::@7 mul_tables_compare::@3 mul_tables_compare::@8 mul_tables_compare::@4 mul_tables_compare::@9 mul_tables_compare::@5 mul_tables_compare::@return init_mul_tables_asm init_mul_tables_asm::@return init_mul_tables init_mul_tables::@1 init_mul_tables::@3 init_mul_tables::@2 init_mul_tables::@return -Added new block during phi lifting mul_tables_compare::@11(between mul_tables_compare::@5 and mul_tables_compare::@1) -Added new block during phi lifting init_mul_tables::@5(between init_mul_tables::@2 and init_mul_tables::@1) -Added new block during phi lifting init_mul_tables::@6(between init_mul_tables::@1 and init_mul_tables::@2) -Block Sequence Planned @begin @4 @end main main::@1 main::@2 main::@return mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@6 mul_tables_compare::@2 mul_tables_compare::@7 mul_tables_compare::@3 mul_tables_compare::@8 mul_tables_compare::@4 mul_tables_compare::@9 mul_tables_compare::@5 mul_tables_compare::@return mul_tables_compare::@11 init_mul_tables_asm init_mul_tables_asm::@return init_mul_tables init_mul_tables::@1 init_mul_tables::@3 init_mul_tables::@2 init_mul_tables::@return init_mul_tables::@5 init_mul_tables::@6 +Block Sequence Planned @begin @10 @end main main::@1 main::@2 main::@return mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@6 mul_tables_compare::@7 mul_tables_compare::@8 mul_tables_compare::@9 mul_tables_compare::@return mul_tables_compare::@2 print_word print_word::@1 print_word::@return print_byte print_byte::@1 print_byte::@return print_char print_char::@return print_str print_str::@1 print_str::@return print_str::@2 print_cls print_cls::@1 print_cls::@return init_mul_tables_asm init_mul_tables_asm::@return init_mul_tables init_mul_tables::@1 init_mul_tables::@5 init_mul_tables::@2 init_mul_tables::@3 init_mul_tables::@7 init_mul_tables::@4 init_mul_tables::@8 init_mul_tables::@return +Added new block during phi lifting mul_tables_compare::@11(between mul_tables_compare::@2 and mul_tables_compare::@1) +Added new block during phi lifting print_cls::@3(between print_cls::@1 and print_cls::@1) +Added new block during phi lifting init_mul_tables::@9(between init_mul_tables::@2 and init_mul_tables::@1) +Added new block during phi lifting init_mul_tables::@10(between init_mul_tables::@1 and init_mul_tables::@2) +Added new block during phi lifting init_mul_tables::@11(between init_mul_tables::@4 and init_mul_tables::@3) +Added new block during phi lifting init_mul_tables::@12(between init_mul_tables::@3 and init_mul_tables::@4) +Block Sequence Planned @begin @10 @end main main::@1 main::@2 main::@return mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@6 mul_tables_compare::@7 mul_tables_compare::@8 mul_tables_compare::@9 mul_tables_compare::@return mul_tables_compare::@2 mul_tables_compare::@11 print_word print_word::@1 print_word::@return print_byte print_byte::@1 print_byte::@return print_char print_char::@return print_str print_str::@1 print_str::@return print_str::@2 print_cls print_cls::@1 print_cls::@return print_cls::@3 init_mul_tables_asm init_mul_tables_asm::@return init_mul_tables init_mul_tables::@1 init_mul_tables::@5 init_mul_tables::@2 init_mul_tables::@3 init_mul_tables::@7 init_mul_tables::@4 init_mul_tables::@8 init_mul_tables::@return init_mul_tables::@11 init_mul_tables::@12 init_mul_tables::@9 init_mul_tables::@10 Adding NOP phi() at start of @begin -Adding NOP phi() at start of @4 +Adding NOP phi() at start of @10 Adding NOP phi() at start of @end Adding NOP phi() at start of main Adding NOP phi() at start of main::@1 Adding NOP phi() at start of main::@2 +Adding NOP phi() at start of mul_tables_compare::@6 +Adding NOP phi() at start of print_cls Adding NOP phi() at start of init_mul_tables +Adding NOP phi() at start of init_mul_tables::@7 CALL GRAPH Calls in [] to main:2 Calls in [main] to init_mul_tables:5 init_mul_tables_asm:7 mul_tables_compare:9 +Calls in [mul_tables_compare] to print_cls:15 print_str:17 print_word:20 print_str:22 print_word:25 +Calls in [print_word] to print_byte:38 print_byte:42 +Calls in [print_byte] to print_char:49 print_char:54 Propagating live ranges... Propagating live ranges... @@ -786,29 +1723,60 @@ Propagating live ranges... Propagating live ranges... Propagating live ranges... Propagating live ranges... -Created 8 initial phi equivalence classes -Coalesced [24] mul_tables_compare::i#11 ← mul_tables_compare::i#1 -Coalesced [34] init_mul_tables::sqr#8 ← init_mul_tables::sqr#2 -Coalesced [35] init_mul_tables::x_2#7 ← init_mul_tables::x_2#1 -Coalesced [46] init_mul_tables::c#5 ← init_mul_tables::c#1 -Coalesced [47] init_mul_tables::sqr#6 ← init_mul_tables::sqr#1 -Coalesced [48] init_mul_tables::sqr_lo#5 ← init_mul_tables::sqr_lo#1 -Coalesced [49] init_mul_tables::sqr_hi#5 ← init_mul_tables::sqr_hi#1 -Coalesced [50] init_mul_tables::x_2#5 ← init_mul_tables::x_2#2 -Coalesced [51] init_mul_tables::sqr#7 ← init_mul_tables::sqr#4 -Coalesced (already) [52] init_mul_tables::x_2#6 ← init_mul_tables::x_2#3 -Coalesced down to 6 phi equivalence classes +Created 25 initial phi equivalence classes +Coalesced [19] print_word::w#4 ← print_word::w#0 +Coalesced [21] char_cursor#58 ← char_cursor#10 +Coalesced [24] print_word::w#5 ← print_word::w#1 +Coalesced [26] char_cursor#53 ← char_cursor#10 +Coalesced [32] mul_tables_compare::kc_sqr#9 ← mul_tables_compare::kc_sqr#1 +Coalesced [33] mul_tables_compare::asm_sqr#7 ← mul_tables_compare::asm_sqr#1 +Coalesced [36] print_byte::b#4 ← print_byte::b#0 +Coalesced [37] char_cursor#54 ← char_cursor#19 +Coalesced [40] print_byte::b#5 ← print_byte::b#1 +Coalesced [41] char_cursor#55 ← char_cursor#10 +Coalesced [47] print_char::ch#3 ← print_char::ch#0 +Coalesced [48] char_cursor#56 ← char_cursor#39 +Coalesced [52] print_char::ch#4 ← print_char::ch#1 +Coalesced (already) [53] char_cursor#57 ← char_cursor#10 +Coalesced [61] print_str::str#6 ← print_str::str#5 +Coalesced (already) [62] char_cursor#59 ← char_cursor#44 +Coalesced [69] print_str::str#7 ← print_str::str#0 +Coalesced [70] char_cursor#60 ← char_cursor#1 +Coalesced [77] print_cls::sc#3 ← print_cls::sc#1 +Coalesced [91] init_mul_tables::sqr#8 ← init_mul_tables::sqr#2 +Coalesced [92] init_mul_tables::x_2#7 ← init_mul_tables::x_2#1 +Coalesced [115] init_mul_tables::x_255#5 ← init_mul_tables::x_255#1 +Coalesced [116] init_mul_tables::sqr2_lo#5 ← init_mul_tables::sqr2_lo#1 +Coalesced [117] init_mul_tables::sqr2_hi#5 ← init_mul_tables::sqr2_hi#1 +Coalesced [118] init_mul_tables::dir#4 ← init_mul_tables::dir#3 +Coalesced (already) [119] init_mul_tables::dir#5 ← init_mul_tables::dir#2 +Coalesced [120] init_mul_tables::c#5 ← init_mul_tables::c#1 +Coalesced [121] init_mul_tables::sqr#6 ← init_mul_tables::sqr#1 +Coalesced [122] init_mul_tables::sqr1_lo#5 ← init_mul_tables::sqr1_lo#1 +Coalesced [123] init_mul_tables::sqr1_hi#5 ← init_mul_tables::sqr1_hi#1 +Coalesced [124] init_mul_tables::x_2#5 ← init_mul_tables::x_2#2 +Coalesced [125] init_mul_tables::sqr#7 ← init_mul_tables::sqr#4 +Coalesced (already) [126] init_mul_tables::x_2#6 ← init_mul_tables::x_2#3 +Coalesced down to 17 phi equivalence classes Culled Empty Block (label) mul_tables_compare::@11 -Culled Empty Block (label) init_mul_tables::@5 -Culled Empty Block (label) init_mul_tables::@6 -Block Sequence Planned @begin @4 @end main main::@1 main::@2 main::@return mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@6 mul_tables_compare::@2 mul_tables_compare::@7 mul_tables_compare::@3 mul_tables_compare::@8 mul_tables_compare::@4 mul_tables_compare::@9 mul_tables_compare::@5 mul_tables_compare::@return init_mul_tables_asm init_mul_tables_asm::@return init_mul_tables init_mul_tables::@1 init_mul_tables::@3 init_mul_tables::@2 init_mul_tables::@return +Culled Empty Block (label) print_cls::@3 +Culled Empty Block (label) init_mul_tables::@7 +Culled Empty Block (label) init_mul_tables::@11 +Not culling empty block because it shares successor with its predecessor. (label) init_mul_tables::@12 +Culled Empty Block (label) init_mul_tables::@9 +Culled Empty Block (label) init_mul_tables::@10 +Block Sequence Planned @begin @10 @end main main::@1 main::@2 main::@return mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@6 mul_tables_compare::@7 mul_tables_compare::@8 mul_tables_compare::@9 mul_tables_compare::@return mul_tables_compare::@2 print_word print_word::@1 print_word::@return print_byte print_byte::@1 print_byte::@return print_char print_char::@return print_str print_str::@1 print_str::@return print_str::@2 print_cls print_cls::@1 print_cls::@return init_mul_tables_asm init_mul_tables_asm::@return init_mul_tables init_mul_tables::@1 init_mul_tables::@5 init_mul_tables::@2 init_mul_tables::@3 init_mul_tables::@4 init_mul_tables::@8 init_mul_tables::@return init_mul_tables::@12 Adding NOP phi() at start of @begin -Adding NOP phi() at start of @4 +Adding NOP phi() at start of @10 Adding NOP phi() at start of @end Adding NOP phi() at start of main Adding NOP phi() at start of main::@1 Adding NOP phi() at start of main::@2 +Adding NOP phi() at start of mul_tables_compare::@6 +Adding NOP phi() at start of mul_tables_compare::@8 +Adding NOP phi() at start of print_cls Adding NOP phi() at start of init_mul_tables +Adding NOP phi() at start of init_mul_tables::@12 Propagating live ranges... Propagating live ranges... Propagating live ranges... @@ -824,14 +1792,14 @@ Propagating live ranges... FINAL CONTROL FLOW GRAPH @begin: scope:[] from [0] phi() [ ] ( ) - to:@4 -@4: scope:[] from @begin + to:@10 +@10: scope:[] from @begin [1] phi() [ ] ( ) [2] call main param-assignment [ ] ( ) to:@end -@end: scope:[] from @4 +@end: scope:[] from @10 [3] phi() [ ] ( ) -main: scope:[main] from @4 +main: scope:[main] from @10 [4] phi() [ ] ( main:2 [ ] ) [5] call init_mul_tables param-assignment [ ] ( main:2 [ ] ) to:main::@1 @@ -849,128 +1817,269 @@ main::@return: scope:[main] from main::@2 mul_tables_compare: scope:[mul_tables_compare] from main::@2 [11] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 5 [ ] ( main:2::mul_tables_compare:9 [ ] ) to:mul_tables_compare::@1 -mul_tables_compare::@1: scope:[mul_tables_compare] from mul_tables_compare mul_tables_compare::@5 - [12] (byte) mul_tables_compare::i#10 ← phi( mul_tables_compare/(byte/signed byte/word/signed word) 0 mul_tables_compare::@5/(byte) mul_tables_compare::i#1 ) [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) - [13] if(*((const byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) - to:mul_tables_compare::@6 -mul_tables_compare::@6: scope:[mul_tables_compare] from mul_tables_compare::@1 - [14] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) - to:mul_tables_compare::@2 -mul_tables_compare::@2: scope:[mul_tables_compare] from mul_tables_compare::@1 mul_tables_compare::@6 - [15] if(*((const byte[512]) mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@3 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) - to:mul_tables_compare::@7 -mul_tables_compare::@7: scope:[mul_tables_compare] from mul_tables_compare::@2 - [16] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) +mul_tables_compare::@1: scope:[mul_tables_compare] from mul_tables_compare mul_tables_compare::@2 + [12] (byte*) mul_tables_compare::asm_sqr#2 ← phi( mul_tables_compare/(const byte[512]) asm_mul_sqr1_lo#0 mul_tables_compare::@2/(byte*) mul_tables_compare::asm_sqr#1 ) [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) + [12] (byte*) mul_tables_compare::kc_sqr#2 ← phi( mul_tables_compare/(const byte[512]) mul_sqr1_lo#0 mul_tables_compare::@2/(byte*) mul_tables_compare::kc_sqr#1 ) [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) + [13] if(*((byte*) mul_tables_compare::kc_sqr#2)==*((byte*) mul_tables_compare::asm_sqr#2)) goto mul_tables_compare::@2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) to:mul_tables_compare::@3 -mul_tables_compare::@3: scope:[mul_tables_compare] from mul_tables_compare::@2 mul_tables_compare::@7 - [17] if(*((const byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@4 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) +mul_tables_compare::@3: scope:[mul_tables_compare] from mul_tables_compare::@1 + [14] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) + [15] call print_cls param-assignment [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) + to:mul_tables_compare::@6 +mul_tables_compare::@6: scope:[mul_tables_compare] from mul_tables_compare::@3 + [16] phi() [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) + [17] call print_str param-assignment [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 ] ) + to:mul_tables_compare::@7 +mul_tables_compare::@7: scope:[mul_tables_compare] from mul_tables_compare::@6 + [18] (word) print_word::w#0 ← ((word)) (byte*) mul_tables_compare::asm_sqr#2 [ mul_tables_compare::kc_sqr#2 print_word::w#0 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 print_word::w#0 char_cursor#19 ] ) + [19] call print_word param-assignment [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] ) to:mul_tables_compare::@8 -mul_tables_compare::@8: scope:[mul_tables_compare] from mul_tables_compare::@3 - [18] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) - to:mul_tables_compare::@4 -mul_tables_compare::@4: scope:[mul_tables_compare] from mul_tables_compare::@3 mul_tables_compare::@8 - [19] if(*((const byte[512]) mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@5 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) +mul_tables_compare::@8: scope:[mul_tables_compare] from mul_tables_compare::@7 + [20] phi() [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] ) + [21] call print_str param-assignment [ mul_tables_compare::kc_sqr#2 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 char_cursor#19 ] ) to:mul_tables_compare::@9 -mul_tables_compare::@9: scope:[mul_tables_compare] from mul_tables_compare::@4 - [20] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) - to:mul_tables_compare::@5 -mul_tables_compare::@5: scope:[mul_tables_compare] from mul_tables_compare::@4 mul_tables_compare::@9 - [21] (byte) mul_tables_compare::i#1 ← ++ (byte) mul_tables_compare::i#10 [ mul_tables_compare::i#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#1 ] ) - [22] if((byte) mul_tables_compare::i#1!=(byte/signed byte/word/signed word) 0) goto mul_tables_compare::@1 [ mul_tables_compare::i#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#1 ] ) +mul_tables_compare::@9: scope:[mul_tables_compare] from mul_tables_compare::@8 + [22] (word) print_word::w#1 ← ((word)) (byte*) mul_tables_compare::kc_sqr#2 [ print_word::w#1 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ print_word::w#1 char_cursor#19 ] ) + [23] call print_word param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9 [ char_cursor#10 ] ) to:mul_tables_compare::@return -mul_tables_compare::@return: scope:[mul_tables_compare] from mul_tables_compare::@5 - [23] return [ ] ( main:2::mul_tables_compare:9 [ ] ) +mul_tables_compare::@return: scope:[mul_tables_compare] from mul_tables_compare::@2 mul_tables_compare::@9 + [24] (byte*) char_cursor#17 ← phi( mul_tables_compare::@9/(byte*) char_cursor#10 mul_tables_compare::@2/((byte*))(word/signed word) 1024 ) [ ] ( main:2::mul_tables_compare:9 [ ] ) + [25] return [ ] ( main:2::mul_tables_compare:9 [ ] ) + to:@return +mul_tables_compare::@2: scope:[mul_tables_compare] from mul_tables_compare::@1 + [26] (byte*) mul_tables_compare::asm_sqr#1 ← ++ (byte*) mul_tables_compare::asm_sqr#2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#1 ] ) + [27] (byte*) mul_tables_compare::kc_sqr#1 ← ++ (byte*) mul_tables_compare::kc_sqr#2 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ) + [28] if((byte*) mul_tables_compare::kc_sqr#1<(const byte[512]) mul_sqr1_lo#0+(word/signed word) 512*(byte/signed byte/word/signed word) 4) goto mul_tables_compare::@1 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ) + to:mul_tables_compare::@return +print_word: scope:[print_word] from mul_tables_compare::@7 mul_tables_compare::@9 + [29] (word) print_word::w#2 ← phi( mul_tables_compare::@7/(word) print_word::w#0 mul_tables_compare::@9/(word) print_word::w#1 ) [ print_word::w#2 char_cursor#19 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#19 ] main:2::mul_tables_compare:9::print_word:23 [ print_word::w#2 char_cursor#19 ] ) + [30] (byte) print_byte::b#0 ← > (word) print_word::w#2 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#0 char_cursor#19 ] main:2::mul_tables_compare:9::print_word:23 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ) + [31] call print_byte param-assignment [ char_cursor#10 print_word::w#2 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_word::w#2 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 print_word::w#2 ] ) + to:print_word::@1 +print_word::@1: scope:[print_word] from print_word + [32] (byte) print_byte::b#1 ← < (word) print_word::w#2 [ char_cursor#10 print_byte::b#1 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::b#1 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 print_byte::b#1 ] ) + [33] call print_byte param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 ] ) + to:print_word::@return +print_word::@return: scope:[print_word] from print_word::@1 + [34] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 ] ) + to:@return +print_byte: scope:[print_byte] from print_word print_word::@1 + [35] (byte*) char_cursor#39 ← phi( print_word/(byte*) char_cursor#19 print_word::@1/(byte*) char_cursor#10 ) [ print_byte::b#2 char_cursor#39 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 ] ) + [35] (byte) print_byte::b#2 ← phi( print_word/(byte) print_byte::b#0 print_word::@1/(byte) print_byte::b#1 ) [ print_byte::b#2 char_cursor#39 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 ] ) + [36] (byte~) print_byte::$0 ← (byte) print_byte::b#2 >> (byte/signed byte/word/signed word) 4 [ print_byte::b#2 char_cursor#39 print_byte::$0 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 print_byte::$0 ] ) + [37] (byte) print_char::ch#0 ← *((const byte[]) print_byte::hextab#0 + (byte~) print_byte::$0) [ print_byte::b#2 char_cursor#39 print_char::ch#0 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 print_char::ch#0 ] ) + [38] call print_char param-assignment [ char_cursor#10 print_byte::b#2 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_byte::b#2 ] ) + to:print_byte::@1 +print_byte::@1: scope:[print_byte] from print_byte + [39] (byte~) print_byte::$2 ← (byte) print_byte::b#2 & (byte/signed byte/word/signed word) 15 [ char_cursor#10 print_byte::$2 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_byte::$2 ] ) + [40] (byte) print_char::ch#1 ← *((const byte[]) print_byte::hextab#0 + (byte~) print_byte::$2) [ char_cursor#10 print_char::ch#1 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_char::ch#1 ] ) + [41] call print_char param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 ] ) + to:print_byte::@return +print_byte::@return: scope:[print_byte] from print_byte::@1 + [42] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 ] ) + to:@return +print_char: scope:[print_char] from print_byte print_byte::@1 + [43] (byte*) char_cursor#27 ← phi( print_byte/(byte*) char_cursor#39 print_byte::@1/(byte*) char_cursor#10 ) [ print_char::ch#2 char_cursor#27 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ print_char::ch#2 char_cursor#27 ] ) + [43] (byte) print_char::ch#2 ← phi( print_byte/(byte) print_char::ch#0 print_byte::@1/(byte) print_char::ch#1 ) [ print_char::ch#2 char_cursor#27 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 print_char::ch#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ print_char::ch#2 char_cursor#27 ] ) + [44] *((byte*) char_cursor#27) ← (byte) print_char::ch#2 [ char_cursor#27 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#27 ] ) + [45] (byte*) char_cursor#10 ← ++ (byte*) char_cursor#27 [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#10 ] ) + to:print_char::@return +print_char::@return: scope:[print_char] from print_char + [46] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#10 ] ) + to:@return +print_str: scope:[print_str] from mul_tables_compare::@6 mul_tables_compare::@8 + [47] (byte*) char_cursor#44 ← phi( mul_tables_compare::@6/((byte*))(word/signed word) 1024 mul_tables_compare::@8/(byte*) char_cursor#10 ) [ print_str::str#5 char_cursor#44 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#5 char_cursor#44 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#5 char_cursor#44 ] ) + [47] (byte*) print_str::str#5 ← phi( mul_tables_compare::@6/(const string) mul_tables_compare::str mul_tables_compare::@8/(const string) mul_tables_compare::str1 ) [ print_str::str#5 char_cursor#44 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#5 char_cursor#44 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#5 char_cursor#44 ] ) + to:print_str::@1 +print_str::@1: scope:[print_str] from print_str print_str::@2 + [48] (byte*) char_cursor#19 ← phi( print_str/(byte*) char_cursor#44 print_str::@2/(byte*) char_cursor#1 ) [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) + [48] (byte*) print_str::str#3 ← phi( print_str/(byte*) print_str::str#5 print_str::@2/(byte*) print_str::str#0 ) [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) + [49] if(*((byte*) print_str::str#3)!=(byte) '@') goto print_str::@2 [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) + to:print_str::@return +print_str::@return: scope:[print_str] from print_str::@1 + [50] return [ char_cursor#19 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 ] ) + to:@return +print_str::@2: scope:[print_str] from print_str::@1 + [51] *((byte*) char_cursor#19) ← *((byte*) print_str::str#3) [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) + [52] (byte*) char_cursor#1 ← ++ (byte*) char_cursor#19 [ print_str::str#3 char_cursor#1 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#3 char_cursor#1 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#3 char_cursor#1 ] ) + [53] (byte*) print_str::str#0 ← ++ (byte*) print_str::str#3 [ print_str::str#0 char_cursor#1 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#0 char_cursor#1 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#0 char_cursor#1 ] ) + to:print_str::@1 +print_cls: scope:[print_cls] from mul_tables_compare::@3 + [54] phi() [ ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) + to:print_cls::@1 +print_cls::@1: scope:[print_cls] from print_cls print_cls::@1 + [55] (byte*) print_cls::sc#2 ← phi( print_cls/((byte*))(word/signed word) 1024 print_cls::@1/(byte*) print_cls::sc#1 ) [ print_cls::sc#2 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#2 ] ) + [56] *((byte*) print_cls::sc#2) ← (byte) ' ' [ print_cls::sc#2 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#2 ] ) + [57] (byte*) print_cls::sc#1 ← ++ (byte*) print_cls::sc#2 [ print_cls::sc#1 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#1 ] ) + [58] if((byte*) print_cls::sc#1!=(word/signed word) 1024+(word/signed word) 1000) goto print_cls::@1 [ print_cls::sc#1 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#1 ] ) + to:print_cls::@return +print_cls::@return: scope:[print_cls] from print_cls::@1 + [59] return [ ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) to:@return init_mul_tables_asm: scope:[init_mul_tables_asm] from main::@1 - asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr_lo,xbnelb1incml0+2incml1+2clcinybnelb1 } + asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr1_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr1_lo,xbnelb1incml0+2incml1+2clcinybnelb1ldx#$00ldy#$ff!:ldaasm_mul_sqr1_hi+1,xstaasm_mul_sqr2_hi+$100,xldaasm_mul_sqr1_hi,xstaasm_mul_sqr2_hi,yldaasm_mul_sqr1_lo+1,xstaasm_mul_sqr2_lo+$100,xldaasm_mul_sqr1_lo,xstaasm_mul_sqr2_lo,ydeyinxbne!- } + [61] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) + [62] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) + [63] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) + [64] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) to:init_mul_tables_asm::@return init_mul_tables_asm::@return: scope:[init_mul_tables_asm] from init_mul_tables_asm - [25] return [ ] ( main:2::init_mul_tables_asm:7 [ ] ) + [65] return [ ] ( main:2::init_mul_tables_asm:7 [ ] ) to:@return init_mul_tables: scope:[init_mul_tables] from main - [26] phi() [ ] ( main:2::init_mul_tables:5 [ ] ) + [66] phi() [ ] ( main:2::init_mul_tables:5 [ ] ) to:init_mul_tables::@1 init_mul_tables::@1: scope:[init_mul_tables] from init_mul_tables init_mul_tables::@2 - [27] (byte) init_mul_tables::x_2#3 ← phi( init_mul_tables/(byte/signed byte/word/signed word) 0 init_mul_tables::@2/(byte) init_mul_tables::x_2#2 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ) - [27] (byte*) init_mul_tables::sqr_hi#2 ← phi( init_mul_tables/(const byte[512]) mul_sqr_hi#0+(byte/signed byte/word/signed word) 1 init_mul_tables::@2/(byte*) init_mul_tables::sqr_hi#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ) - [27] (byte*) init_mul_tables::sqr_lo#2 ← phi( init_mul_tables/(const byte[512]) mul_sqr_lo#0+(byte/signed byte/word/signed word) 1 init_mul_tables::@2/(byte*) init_mul_tables::sqr_lo#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ) - [27] (word) init_mul_tables::sqr#4 ← phi( init_mul_tables/(byte/signed byte/word/signed word) 0 init_mul_tables::@2/(word) init_mul_tables::sqr#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ) - [27] (byte) init_mul_tables::c#2 ← phi( init_mul_tables/(byte/signed byte/word/signed word) 0 init_mul_tables::@2/(byte) init_mul_tables::c#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 ] ) - [28] (byte) init_mul_tables::c#1 ← ++ (byte) init_mul_tables::c#2 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) - [29] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) - [30] if((byte~) init_mul_tables::$2!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@2 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) - to:init_mul_tables::@3 -init_mul_tables::@3: scope:[init_mul_tables] from init_mul_tables::@1 - [31] (byte) init_mul_tables::x_2#1 ← ++ (byte) init_mul_tables::x_2#3 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ) - [32] (word) init_mul_tables::sqr#2 ← ++ (word) init_mul_tables::sqr#4 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ) + [67] (byte) init_mul_tables::x_2#3 ← phi( init_mul_tables/(byte/signed byte/word/signed word) 0 init_mul_tables::@2/(byte) init_mul_tables::x_2#2 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ) + [67] (byte*) init_mul_tables::sqr1_hi#2 ← phi( init_mul_tables/(const byte[512]) mul_sqr1_hi#0+(byte/signed byte/word/signed word) 1 init_mul_tables::@2/(byte*) init_mul_tables::sqr1_hi#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ) + [67] (byte*) init_mul_tables::sqr1_lo#2 ← phi( init_mul_tables/(const byte[512]) mul_sqr1_lo#0+(byte/signed byte/word/signed word) 1 init_mul_tables::@2/(byte*) init_mul_tables::sqr1_lo#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ) + [67] (word) init_mul_tables::sqr#4 ← phi( init_mul_tables/(byte/signed byte/word/signed word) 0 init_mul_tables::@2/(word) init_mul_tables::sqr#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ) + [67] (byte) init_mul_tables::c#2 ← phi( init_mul_tables/(byte/signed byte/word/signed word) 0 init_mul_tables::@2/(byte) init_mul_tables::c#1 ) [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#2 init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 ] ) + [68] (byte) init_mul_tables::c#1 ← ++ (byte) init_mul_tables::c#2 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) + [69] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) + [70] if((byte~) init_mul_tables::$2!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@2 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) + to:init_mul_tables::@5 +init_mul_tables::@5: scope:[init_mul_tables] from init_mul_tables::@1 + [71] (byte) init_mul_tables::x_2#1 ← ++ (byte) init_mul_tables::x_2#3 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ) + [72] (word) init_mul_tables::sqr#2 ← ++ (word) init_mul_tables::sqr#4 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ) to:init_mul_tables::@2 -init_mul_tables::@2: scope:[init_mul_tables] from init_mul_tables::@1 init_mul_tables::@3 - [33] (byte) init_mul_tables::x_2#2 ← phi( init_mul_tables::@1/(byte) init_mul_tables::x_2#3 init_mul_tables::@3/(byte) init_mul_tables::x_2#1 ) [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) - [33] (word) init_mul_tables::sqr#3 ← phi( init_mul_tables::@1/(word) init_mul_tables::sqr#4 init_mul_tables::@3/(word) init_mul_tables::sqr#2 ) [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) - [34] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) - [35] *((byte*) init_mul_tables::sqr_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) - [36] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) - [37] *((byte*) init_mul_tables::sqr_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) - [38] (byte*) init_mul_tables::sqr_hi#1 ← ++ (byte*) init_mul_tables::sqr_hi#2 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) - [39] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) - [40] (byte*) init_mul_tables::sqr_lo#1 ← ++ (byte*) init_mul_tables::sqr_lo#2 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) - [41] if((byte*) init_mul_tables::sqr_lo#1!=(const byte[512]) mul_sqr_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) +init_mul_tables::@2: scope:[init_mul_tables] from init_mul_tables::@1 init_mul_tables::@5 + [73] (byte) init_mul_tables::x_2#2 ← phi( init_mul_tables::@1/(byte) init_mul_tables::x_2#3 init_mul_tables::@5/(byte) init_mul_tables::x_2#1 ) [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) + [73] (word) init_mul_tables::sqr#3 ← phi( init_mul_tables::@1/(word) init_mul_tables::sqr#4 init_mul_tables::@5/(word) init_mul_tables::sqr#2 ) [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) + [74] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) + [75] *((byte*) init_mul_tables::sqr1_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) + [76] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) + [77] *((byte*) init_mul_tables::sqr1_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) + [78] (byte*) init_mul_tables::sqr1_hi#1 ← ++ (byte*) init_mul_tables::sqr1_hi#2 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) + [79] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) + [80] (byte*) init_mul_tables::sqr1_lo#1 ← ++ (byte*) init_mul_tables::sqr1_lo#2 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) + [81] if((byte*) init_mul_tables::sqr1_lo#1!=(const byte[512]) mul_sqr1_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) + to:init_mul_tables::@3 +init_mul_tables::@3: scope:[init_mul_tables] from init_mul_tables::@2 init_mul_tables::@4 + [82] (byte) init_mul_tables::dir#2 ← phi( init_mul_tables::@4/(byte) init_mul_tables::dir#3 init_mul_tables::@2/(byte/word/signed word) 255 ) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) + [82] (byte*) init_mul_tables::sqr2_hi#2 ← phi( init_mul_tables::@4/(byte*) init_mul_tables::sqr2_hi#1 init_mul_tables::@2/(const byte[512]) mul_sqr2_hi#0 ) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) + [82] (byte*) init_mul_tables::sqr2_lo#2 ← phi( init_mul_tables::@4/(byte*) init_mul_tables::sqr2_lo#1 init_mul_tables::@2/(const byte[512]) mul_sqr2_lo#0 ) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) + [82] (byte) init_mul_tables::x_255#2 ← phi( init_mul_tables::@4/(byte) init_mul_tables::x_255#1 init_mul_tables::@2/((byte))-(byte/signed byte/word/signed word) 1 ) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) + [83] *((byte*) init_mul_tables::sqr2_lo#2) ← *((const byte[512]) mul_sqr1_lo#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) + [84] *((byte*) init_mul_tables::sqr2_hi#2) ← *((const byte[512]) mul_sqr1_hi#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) + [85] (byte*) init_mul_tables::sqr2_hi#1 ← ++ (byte*) init_mul_tables::sqr2_hi#2 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::sqr2_hi#1 ] ) + [86] (byte) init_mul_tables::x_255#1 ← (byte) init_mul_tables::x_255#2 + (byte) init_mul_tables::dir#2 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) + [87] if((byte) init_mul_tables::x_255#1!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@12 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) + to:init_mul_tables::@4 +init_mul_tables::@4: scope:[init_mul_tables] from init_mul_tables::@12 init_mul_tables::@3 + [88] (byte) init_mul_tables::dir#3 ← phi( init_mul_tables::@12/(byte) init_mul_tables::dir#2 init_mul_tables::@3/(byte/signed byte/word/signed word) 1 ) [ init_mul_tables::sqr2_lo#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) + [89] (byte*) init_mul_tables::sqr2_lo#1 ← ++ (byte*) init_mul_tables::sqr2_lo#2 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) + [90] if((byte*) init_mul_tables::sqr2_lo#1!=(const byte[512]) mul_sqr2_lo#0+(word/signed word) 511) goto init_mul_tables::@3 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) + to:init_mul_tables::@8 +init_mul_tables::@8: scope:[init_mul_tables] from init_mul_tables::@4 + [91] *((const byte[512]) mul_sqr2_lo#0+(word/signed word) 511) ← *((const byte[512]) mul_sqr1_lo#0+(word/signed word) 256) [ ] ( main:2::init_mul_tables:5 [ ] ) + [92] *((const byte[512]) mul_sqr2_hi#0+(word/signed word) 511) ← *((const byte[512]) mul_sqr1_hi#0+(word/signed word) 256) [ ] ( main:2::init_mul_tables:5 [ ] ) to:init_mul_tables::@return -init_mul_tables::@return: scope:[init_mul_tables] from init_mul_tables::@2 - [42] return [ ] ( main:2::init_mul_tables:5 [ ] ) +init_mul_tables::@return: scope:[init_mul_tables] from init_mul_tables::@8 + [93] return [ ] ( main:2::init_mul_tables:5 [ ] ) to:@return +init_mul_tables::@12: scope:[init_mul_tables] from init_mul_tables::@3 + [94] phi() [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) + to:init_mul_tables::@4 DOMINATORS @begin dominated by @begin -@4 dominated by @begin @4 -@end dominated by @end @begin @4 -main dominated by main @begin @4 -main::@1 dominated by main main::@1 @begin @4 -main::@2 dominated by main main::@1 main::@2 @begin @4 -main::@return dominated by main::@return main main::@1 main::@2 @begin @4 -mul_tables_compare dominated by main main::@1 main::@2 @begin mul_tables_compare @4 -mul_tables_compare::@1 dominated by main main::@1 main::@2 @begin mul_tables_compare @4 mul_tables_compare::@1 -mul_tables_compare::@6 dominated by main main::@1 main::@2 @begin mul_tables_compare @4 mul_tables_compare::@1 mul_tables_compare::@6 -mul_tables_compare::@2 dominated by main main::@1 main::@2 @begin mul_tables_compare @4 mul_tables_compare::@1 mul_tables_compare::@2 -mul_tables_compare::@7 dominated by main main::@1 main::@2 @begin mul_tables_compare @4 mul_tables_compare::@1 mul_tables_compare::@2 mul_tables_compare::@7 -mul_tables_compare::@3 dominated by main main::@1 main::@2 @begin mul_tables_compare @4 mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@2 -mul_tables_compare::@8 dominated by main main::@1 main::@2 @begin mul_tables_compare @4 mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@2 mul_tables_compare::@8 -mul_tables_compare::@4 dominated by main main::@1 main::@2 @begin mul_tables_compare @4 mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@2 mul_tables_compare::@4 -mul_tables_compare::@9 dominated by main main::@1 main::@2 @begin mul_tables_compare @4 mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@2 mul_tables_compare::@4 mul_tables_compare::@9 -mul_tables_compare::@5 dominated by main main::@1 main::@2 @begin mul_tables_compare @4 mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@2 mul_tables_compare::@5 mul_tables_compare::@4 -mul_tables_compare::@return dominated by main main::@1 main::@2 @begin mul_tables_compare mul_tables_compare::@return @4 mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@2 mul_tables_compare::@5 mul_tables_compare::@4 -init_mul_tables_asm dominated by main init_mul_tables_asm main::@1 @begin @4 -init_mul_tables_asm::@return dominated by main init_mul_tables_asm::@return init_mul_tables_asm main::@1 @begin @4 -init_mul_tables dominated by main init_mul_tables @begin @4 -init_mul_tables::@1 dominated by main init_mul_tables @begin @4 init_mul_tables::@1 -init_mul_tables::@3 dominated by main init_mul_tables @begin @4 init_mul_tables::@1 init_mul_tables::@3 -init_mul_tables::@2 dominated by main init_mul_tables @begin @4 init_mul_tables::@2 init_mul_tables::@1 -init_mul_tables::@return dominated by main init_mul_tables init_mul_tables::@return @begin @4 init_mul_tables::@2 init_mul_tables::@1 +@10 dominated by @10 @begin +@end dominated by @end @10 @begin +main dominated by main @10 @begin +main::@1 dominated by main main::@1 @10 @begin +main::@2 dominated by main main::@1 main::@2 @10 @begin +main::@return dominated by main::@return main main::@1 main::@2 @10 @begin +mul_tables_compare dominated by main main::@1 main::@2 @10 @begin mul_tables_compare +mul_tables_compare::@1 dominated by main main::@1 main::@2 @10 @begin mul_tables_compare mul_tables_compare::@1 +mul_tables_compare::@3 dominated by main main::@1 main::@2 @10 @begin mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@3 +mul_tables_compare::@6 dominated by main main::@1 main::@2 @10 @begin mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@6 +mul_tables_compare::@7 dominated by main main::@1 main::@2 @10 @begin mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@7 mul_tables_compare::@6 +mul_tables_compare::@8 dominated by main main::@1 main::@2 @10 @begin mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@7 mul_tables_compare::@6 mul_tables_compare::@8 +mul_tables_compare::@9 dominated by main main::@1 main::@2 @10 @begin mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@7 mul_tables_compare::@6 mul_tables_compare::@9 mul_tables_compare::@8 +mul_tables_compare::@return dominated by main main::@1 main::@2 @10 @begin mul_tables_compare mul_tables_compare::@return mul_tables_compare::@1 +mul_tables_compare::@2 dominated by main main::@1 main::@2 @10 @begin mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@2 +print_word dominated by main print_word main::@1 main::@2 @10 @begin mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@7 mul_tables_compare::@6 +print_word::@1 dominated by main print_word main::@1 main::@2 print_word::@1 @10 @begin mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@7 mul_tables_compare::@6 +print_word::@return dominated by main print_word main::@1 main::@2 print_word::@1 @10 @begin mul_tables_compare mul_tables_compare::@1 mul_tables_compare::@3 print_word::@return mul_tables_compare::@7 mul_tables_compare::@6 +print_byte dominated by main print_word main::@1 main::@2 @10 @begin mul_tables_compare print_byte mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@7 mul_tables_compare::@6 +print_byte::@1 dominated by main print_word main::@1 main::@2 print_byte::@1 @10 @begin mul_tables_compare print_byte mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@7 mul_tables_compare::@6 +print_byte::@return dominated by main print_word main::@1 main::@2 print_byte::@1 @10 @begin mul_tables_compare print_byte print_byte::@return mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@7 mul_tables_compare::@6 +print_char dominated by main print_word print_char main::@1 main::@2 @10 @begin mul_tables_compare print_byte mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@7 mul_tables_compare::@6 +print_char::@return dominated by main print_word print_char main::@1 main::@2 @10 print_char::@return @begin mul_tables_compare print_byte mul_tables_compare::@1 mul_tables_compare::@3 mul_tables_compare::@7 mul_tables_compare::@6 +print_str dominated by main main::@1 main::@2 @10 @begin mul_tables_compare mul_tables_compare::@1 print_str mul_tables_compare::@3 mul_tables_compare::@6 +print_str::@1 dominated by main print_str::@1 main::@1 main::@2 @10 @begin mul_tables_compare mul_tables_compare::@1 print_str mul_tables_compare::@3 mul_tables_compare::@6 +print_str::@return dominated by print_str::@return main print_str::@1 main::@1 main::@2 @10 @begin mul_tables_compare mul_tables_compare::@1 print_str mul_tables_compare::@3 mul_tables_compare::@6 +print_str::@2 dominated by main print_str::@1 print_str::@2 main::@1 main::@2 @10 @begin mul_tables_compare mul_tables_compare::@1 print_str mul_tables_compare::@3 mul_tables_compare::@6 +print_cls dominated by main main::@1 main::@2 @10 @begin mul_tables_compare print_cls mul_tables_compare::@1 mul_tables_compare::@3 +print_cls::@1 dominated by main main::@1 main::@2 @10 @begin mul_tables_compare print_cls::@1 print_cls mul_tables_compare::@1 mul_tables_compare::@3 +print_cls::@return dominated by main main::@1 print_cls::@return main::@2 @10 @begin mul_tables_compare print_cls::@1 print_cls mul_tables_compare::@1 mul_tables_compare::@3 +init_mul_tables_asm dominated by main init_mul_tables_asm main::@1 @10 @begin +init_mul_tables_asm::@return dominated by main init_mul_tables_asm::@return init_mul_tables_asm main::@1 @10 @begin +init_mul_tables dominated by main init_mul_tables @10 @begin +init_mul_tables::@1 dominated by main init_mul_tables @10 @begin init_mul_tables::@1 +init_mul_tables::@5 dominated by main init_mul_tables @10 @begin init_mul_tables::@5 init_mul_tables::@1 +init_mul_tables::@2 dominated by main init_mul_tables @10 @begin init_mul_tables::@2 init_mul_tables::@1 +init_mul_tables::@3 dominated by main init_mul_tables @10 @begin init_mul_tables::@2 init_mul_tables::@1 init_mul_tables::@3 +init_mul_tables::@4 dominated by main init_mul_tables @10 @begin init_mul_tables::@2 init_mul_tables::@1 init_mul_tables::@4 init_mul_tables::@3 +init_mul_tables::@8 dominated by main init_mul_tables @10 @begin init_mul_tables::@8 init_mul_tables::@2 init_mul_tables::@1 init_mul_tables::@4 init_mul_tables::@3 +init_mul_tables::@return dominated by main init_mul_tables init_mul_tables::@return @10 @begin init_mul_tables::@8 init_mul_tables::@2 init_mul_tables::@1 init_mul_tables::@4 init_mul_tables::@3 +init_mul_tables::@12 dominated by main init_mul_tables @10 @begin init_mul_tables::@2 init_mul_tables::@1 init_mul_tables::@3 init_mul_tables::@12 NATURAL LOOPS -Found back edge: Loop head: mul_tables_compare::@1 tails: mul_tables_compare::@5 blocks: null +Found back edge: Loop head: mul_tables_compare::@1 tails: mul_tables_compare::@2 blocks: null +Found back edge: Loop head: print_str::@1 tails: print_str::@2 blocks: null +Found back edge: Loop head: print_cls::@1 tails: print_cls::@1 blocks: null Found back edge: Loop head: init_mul_tables::@1 tails: init_mul_tables::@2 blocks: null -Populated: Loop head: mul_tables_compare::@1 tails: mul_tables_compare::@5 blocks: mul_tables_compare::@5 mul_tables_compare::@4 mul_tables_compare::@9 mul_tables_compare::@3 mul_tables_compare::@8 mul_tables_compare::@2 mul_tables_compare::@7 mul_tables_compare::@1 mul_tables_compare::@6 -Populated: Loop head: init_mul_tables::@1 tails: init_mul_tables::@2 blocks: init_mul_tables::@2 init_mul_tables::@1 init_mul_tables::@3 -Loop head: mul_tables_compare::@1 tails: mul_tables_compare::@5 blocks: mul_tables_compare::@5 mul_tables_compare::@4 mul_tables_compare::@9 mul_tables_compare::@3 mul_tables_compare::@8 mul_tables_compare::@2 mul_tables_compare::@7 mul_tables_compare::@1 mul_tables_compare::@6 -Loop head: init_mul_tables::@1 tails: init_mul_tables::@2 blocks: init_mul_tables::@2 init_mul_tables::@1 init_mul_tables::@3 +Found back edge: Loop head: init_mul_tables::@3 tails: init_mul_tables::@4 blocks: null +Populated: Loop head: mul_tables_compare::@1 tails: mul_tables_compare::@2 blocks: mul_tables_compare::@2 mul_tables_compare::@1 +Populated: Loop head: print_str::@1 tails: print_str::@2 blocks: print_str::@2 print_str::@1 +Populated: Loop head: print_cls::@1 tails: print_cls::@1 blocks: print_cls::@1 +Populated: Loop head: init_mul_tables::@1 tails: init_mul_tables::@2 blocks: init_mul_tables::@2 init_mul_tables::@1 init_mul_tables::@5 +Populated: Loop head: init_mul_tables::@3 tails: init_mul_tables::@4 blocks: init_mul_tables::@4 init_mul_tables::@12 init_mul_tables::@3 +Loop head: mul_tables_compare::@1 tails: mul_tables_compare::@2 blocks: mul_tables_compare::@2 mul_tables_compare::@1 +Loop head: print_str::@1 tails: print_str::@2 blocks: print_str::@2 print_str::@1 +Loop head: print_cls::@1 tails: print_cls::@1 blocks: print_cls::@1 +Loop head: init_mul_tables::@1 tails: init_mul_tables::@2 blocks: init_mul_tables::@2 init_mul_tables::@1 init_mul_tables::@5 +Loop head: init_mul_tables::@3 tails: init_mul_tables::@4 blocks: init_mul_tables::@4 init_mul_tables::@12 init_mul_tables::@3 NATURAL LOOPS WITH DEPTH Found 0 loops in scope [] Found 0 loops in scope [main] -Found 1 loops in scope [init_mul_tables] - Loop head: init_mul_tables::@1 tails: init_mul_tables::@2 blocks: init_mul_tables::@2 init_mul_tables::@1 init_mul_tables::@3 +Found 2 loops in scope [init_mul_tables] + Loop head: init_mul_tables::@1 tails: init_mul_tables::@2 blocks: init_mul_tables::@2 init_mul_tables::@1 init_mul_tables::@5 + Loop head: init_mul_tables::@3 tails: init_mul_tables::@4 blocks: init_mul_tables::@4 init_mul_tables::@12 init_mul_tables::@3 Found 0 loops in scope [init_mul_tables_asm] Found 1 loops in scope [mul_tables_compare] - Loop head: mul_tables_compare::@1 tails: mul_tables_compare::@5 blocks: mul_tables_compare::@5 mul_tables_compare::@4 mul_tables_compare::@9 mul_tables_compare::@3 mul_tables_compare::@8 mul_tables_compare::@2 mul_tables_compare::@7 mul_tables_compare::@1 mul_tables_compare::@6 -Loop head: mul_tables_compare::@1 tails: mul_tables_compare::@5 blocks: mul_tables_compare::@5 mul_tables_compare::@4 mul_tables_compare::@9 mul_tables_compare::@3 mul_tables_compare::@8 mul_tables_compare::@2 mul_tables_compare::@7 mul_tables_compare::@1 mul_tables_compare::@6 depth: 1 -Loop head: init_mul_tables::@1 tails: init_mul_tables::@2 blocks: init_mul_tables::@2 init_mul_tables::@1 init_mul_tables::@3 depth: 1 + Loop head: mul_tables_compare::@1 tails: mul_tables_compare::@2 blocks: mul_tables_compare::@2 mul_tables_compare::@1 +Found 1 loops in scope [print_cls] + Loop head: print_cls::@1 tails: print_cls::@1 blocks: print_cls::@1 +Found 1 loops in scope [print_str] + Loop head: print_str::@1 tails: print_str::@2 blocks: print_str::@2 print_str::@1 +Found 0 loops in scope [print_word] +Found 0 loops in scope [print_byte] +Found 0 loops in scope [print_char] +Loop head: mul_tables_compare::@1 tails: mul_tables_compare::@2 blocks: mul_tables_compare::@2 mul_tables_compare::@1 depth: 1 +Loop head: print_str::@1 tails: print_str::@2 blocks: print_str::@2 print_str::@1 depth: 1 +Loop head: print_cls::@1 tails: print_cls::@1 blocks: print_cls::@1 depth: 1 +Loop head: init_mul_tables::@1 tails: init_mul_tables::@2 blocks: init_mul_tables::@2 init_mul_tables::@1 init_mul_tables::@5 depth: 1 +Loop head: init_mul_tables::@3 tails: init_mul_tables::@4 blocks: init_mul_tables::@4 init_mul_tables::@12 init_mul_tables::@3 depth: 1 VARIABLE REGISTER WEIGHTS (byte*) BGCOL -(byte[512]) asm_mul_sqr_hi -(byte[512]) asm_mul_sqr_lo +(byte[512]) asm_mul_sqr1_hi +(byte[512]) asm_mul_sqr1_lo +(byte[512]) asm_mul_sqr2_hi +(byte[512]) asm_mul_sqr2_lo +(byte*) char_cursor +(byte*) char_cursor#1 11.0 +(byte*) char_cursor#10 0.7142857142857142 +(byte*) char_cursor#17 20.0 +(byte*) char_cursor#19 3.7 +(byte*) char_cursor#27 4.0 +(byte*) char_cursor#39 2.0 +(byte*) char_cursor#44 4.0 (void()) init_mul_tables() (byte~) init_mul_tables::$2 22.0 (byte~) init_mul_tables::$5 22.0 @@ -978,59 +2087,218 @@ VARIABLE REGISTER WEIGHTS (byte) init_mul_tables::c (byte) init_mul_tables::c#1 2.357142857142857 (byte) init_mul_tables::c#2 22.0 +(byte) init_mul_tables::dir +(byte) init_mul_tables::dir#2 4.714285714285714 +(byte) init_mul_tables::dir#3 7.333333333333333 (word) init_mul_tables::sqr (word) init_mul_tables::sqr#1 7.333333333333333 (word) init_mul_tables::sqr#2 22.0 (word) init_mul_tables::sqr#3 9.166666666666666 (word) init_mul_tables::sqr#4 6.6000000000000005 -(byte*) init_mul_tables::sqr_hi -(byte*) init_mul_tables::sqr_hi#1 5.5 -(byte*) init_mul_tables::sqr_hi#2 3.0 -(byte*) init_mul_tables::sqr_lo -(byte*) init_mul_tables::sqr_lo#1 16.5 -(byte*) init_mul_tables::sqr_lo#2 2.5384615384615383 +(byte*) init_mul_tables::sqr1_hi +(byte*) init_mul_tables::sqr1_hi#1 5.5 +(byte*) init_mul_tables::sqr1_hi#2 3.0 +(byte*) init_mul_tables::sqr1_lo +(byte*) init_mul_tables::sqr1_lo#1 16.5 +(byte*) init_mul_tables::sqr1_lo#2 2.5384615384615383 +(byte*) init_mul_tables::sqr2_hi +(byte*) init_mul_tables::sqr2_hi#1 3.142857142857143 +(byte*) init_mul_tables::sqr2_hi#2 11.0 +(byte*) init_mul_tables::sqr2_lo +(byte*) init_mul_tables::sqr2_lo#1 16.5 +(byte*) init_mul_tables::sqr2_lo#2 4.125 (byte) init_mul_tables::x_2 (byte) init_mul_tables::x_2#1 11.0 (byte) init_mul_tables::x_2#2 4.888888888888889 (byte) init_mul_tables::x_2#3 8.25 +(byte) init_mul_tables::x_255 +(byte) init_mul_tables::x_255#1 5.5 +(byte) init_mul_tables::x_255#2 11.0 (void()) init_mul_tables_asm() +(byte*) init_mul_tables_asm::mem +(byte*) line_cursor (void()) main() -(byte[512]) mul_sqr_hi -(byte[512]) mul_sqr_lo +(byte[512]) mul_sqr1_hi +(byte[512]) mul_sqr1_lo +(byte[512]) mul_sqr2_hi +(byte[512]) mul_sqr2_lo (void()) mul_tables_compare() -(byte) mul_tables_compare::i -(byte) mul_tables_compare::i#1 16.5 -(byte) mul_tables_compare::i#10 12.222222222222221 +(byte*) mul_tables_compare::asm_sqr +(byte*) mul_tables_compare::asm_sqr#1 7.333333333333333 +(byte*) mul_tables_compare::asm_sqr#2 5.833333333333333 +(byte*) mul_tables_compare::kc_sqr +(byte*) mul_tables_compare::kc_sqr#1 16.5 +(byte*) mul_tables_compare::kc_sqr#2 3.1818181818181817 +(void()) print_byte((byte) print_byte::b) +(byte~) print_byte::$0 4.0 +(byte~) print_byte::$2 4.0 +(byte) print_byte::b +(byte) print_byte::b#0 4.0 +(byte) print_byte::b#1 4.0 +(byte) print_byte::b#2 2.0 +(byte[]) print_byte::hextab +(void()) print_char((byte) print_char::ch) +(byte) print_char::ch +(byte) print_char::ch#0 4.0 +(byte) print_char::ch#1 4.0 +(byte) print_char::ch#2 6.0 +(void()) print_cls() +(byte*) print_cls::sc +(byte*) print_cls::sc#1 16.5 +(byte*) print_cls::sc#2 16.5 +(void()) print_str((byte*) print_str::str) +(byte*) print_str::str +(byte*) print_str::str#0 22.0 +(byte*) print_str::str#3 11.5 +(byte*) print_str::str#5 2.0 +(void()) print_word((word) print_word::w) +(word) print_word::w +(word) print_word::w#0 4.0 +(word) print_word::w#1 4.0 +(word) print_word::w#2 2.6666666666666665 Initial phi equivalence classes -[ mul_tables_compare::i#10 mul_tables_compare::i#1 ] +[ mul_tables_compare::kc_sqr#2 mul_tables_compare::kc_sqr#1 ] +[ mul_tables_compare::asm_sqr#2 mul_tables_compare::asm_sqr#1 ] +[ print_word::w#2 print_word::w#0 print_word::w#1 ] +[ print_byte::b#2 print_byte::b#0 print_byte::b#1 ] +[ print_char::ch#2 print_char::ch#0 print_char::ch#1 ] +[ char_cursor#44 char_cursor#27 char_cursor#39 char_cursor#19 char_cursor#17 char_cursor#10 char_cursor#1 ] +[ print_str::str#3 print_str::str#5 print_str::str#0 ] +[ print_cls::sc#2 print_cls::sc#1 ] [ init_mul_tables::c#2 init_mul_tables::c#1 ] -[ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_lo#1 ] -[ init_mul_tables::sqr_hi#2 init_mul_tables::sqr_hi#1 ] +[ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_lo#1 ] +[ init_mul_tables::sqr1_hi#2 init_mul_tables::sqr1_hi#1 ] [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] +[ init_mul_tables::x_255#2 init_mul_tables::x_255#1 ] +[ init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_lo#1 ] +[ init_mul_tables::sqr2_hi#2 init_mul_tables::sqr2_hi#1 ] +[ init_mul_tables::dir#2 init_mul_tables::dir#3 ] +Added variable print_byte::$0 to zero page equivalence class [ print_byte::$0 ] +Added variable print_byte::$2 to zero page equivalence class [ print_byte::$2 ] Added variable init_mul_tables::$2 to zero page equivalence class [ init_mul_tables::$2 ] Added variable init_mul_tables::$5 to zero page equivalence class [ init_mul_tables::$5 ] Added variable init_mul_tables::$6 to zero page equivalence class [ init_mul_tables::$6 ] Complete equivalence classes -[ mul_tables_compare::i#10 mul_tables_compare::i#1 ] +[ mul_tables_compare::kc_sqr#2 mul_tables_compare::kc_sqr#1 ] +[ mul_tables_compare::asm_sqr#2 mul_tables_compare::asm_sqr#1 ] +[ print_word::w#2 print_word::w#0 print_word::w#1 ] +[ print_byte::b#2 print_byte::b#0 print_byte::b#1 ] +[ print_char::ch#2 print_char::ch#0 print_char::ch#1 ] +[ char_cursor#44 char_cursor#27 char_cursor#39 char_cursor#19 char_cursor#17 char_cursor#10 char_cursor#1 ] +[ print_str::str#3 print_str::str#5 print_str::str#0 ] +[ print_cls::sc#2 print_cls::sc#1 ] [ init_mul_tables::c#2 init_mul_tables::c#1 ] -[ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_lo#1 ] -[ init_mul_tables::sqr_hi#2 init_mul_tables::sqr_hi#1 ] +[ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_lo#1 ] +[ init_mul_tables::sqr1_hi#2 init_mul_tables::sqr1_hi#1 ] [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] +[ init_mul_tables::x_255#2 init_mul_tables::x_255#1 ] +[ init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_lo#1 ] +[ init_mul_tables::sqr2_hi#2 init_mul_tables::sqr2_hi#1 ] +[ init_mul_tables::dir#2 init_mul_tables::dir#3 ] +[ print_byte::$0 ] +[ print_byte::$2 ] [ init_mul_tables::$2 ] [ init_mul_tables::$5 ] [ init_mul_tables::$6 ] -Allocated zp ZP_BYTE:2 [ mul_tables_compare::i#10 mul_tables_compare::i#1 ] -Allocated zp ZP_BYTE:3 [ init_mul_tables::c#2 init_mul_tables::c#1 ] -Allocated zp ZP_WORD:4 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_lo#1 ] -Allocated zp ZP_WORD:6 [ init_mul_tables::sqr_hi#2 init_mul_tables::sqr_hi#1 ] -Allocated zp ZP_BYTE:8 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] -Allocated zp ZP_WORD:9 [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] -Allocated zp ZP_BYTE:11 [ init_mul_tables::$2 ] -Allocated zp ZP_BYTE:12 [ init_mul_tables::$5 ] -Allocated zp ZP_BYTE:13 [ init_mul_tables::$6 ] +Allocated zp ZP_WORD:2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::kc_sqr#1 ] +Allocated zp ZP_WORD:4 [ mul_tables_compare::asm_sqr#2 mul_tables_compare::asm_sqr#1 ] +Allocated zp ZP_WORD:6 [ print_word::w#2 print_word::w#0 print_word::w#1 ] +Allocated zp ZP_BYTE:8 [ print_byte::b#2 print_byte::b#0 print_byte::b#1 ] +Allocated zp ZP_BYTE:9 [ print_char::ch#2 print_char::ch#0 print_char::ch#1 ] +Allocated zp ZP_WORD:10 [ char_cursor#44 char_cursor#27 char_cursor#39 char_cursor#19 char_cursor#17 char_cursor#10 char_cursor#1 ] +Allocated zp ZP_WORD:12 [ print_str::str#3 print_str::str#5 print_str::str#0 ] +Allocated zp ZP_WORD:14 [ print_cls::sc#2 print_cls::sc#1 ] +Allocated zp ZP_BYTE:16 [ init_mul_tables::c#2 init_mul_tables::c#1 ] +Allocated zp ZP_WORD:17 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_lo#1 ] +Allocated zp ZP_WORD:19 [ init_mul_tables::sqr1_hi#2 init_mul_tables::sqr1_hi#1 ] +Allocated zp ZP_BYTE:21 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] +Allocated zp ZP_WORD:22 [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] +Allocated zp ZP_BYTE:24 [ init_mul_tables::x_255#2 init_mul_tables::x_255#1 ] +Allocated zp ZP_WORD:25 [ init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_lo#1 ] +Allocated zp ZP_WORD:27 [ init_mul_tables::sqr2_hi#2 init_mul_tables::sqr2_hi#1 ] +Allocated zp ZP_BYTE:29 [ init_mul_tables::dir#2 init_mul_tables::dir#3 ] +Allocated zp ZP_BYTE:30 [ print_byte::$0 ] +Allocated zp ZP_BYTE:31 [ print_byte::$2 ] +Allocated zp ZP_BYTE:32 [ init_mul_tables::$2 ] +Allocated zp ZP_BYTE:33 [ init_mul_tables::$5 ] +Allocated zp ZP_BYTE:34 [ init_mul_tables::$6 ] +Attempting fragment synthesis _deref_pbuc1=vbuc2 +Succesfully loaded fragment _deref_vwuc1=vbuc2 +Succesfully synthesized fragment _deref_pbuc1=vbuc2 (from _deref_vwuc1=vbuc2) +Attempting fragment synthesis pbuz1=pbuc1 +Succesfully loaded fragment pbuz1=vwuc1 +Succesfully synthesized fragment pbuz1=pbuc1 (from pbuz1=vwuc1) +Attempting fragment synthesis _deref_pbuz1_eq__deref_pbuz2_then_la1 +Succesfully loaded fragment vbuaa_eq__deref_pbuz1_then_la1 +Succesfully synthesized fragment _deref_pbuz1_eq__deref_pbuz2_then_la1 (from vbuaa_eq__deref_pbuz1_then_la1) +Succesfully loaded fragment vwuz1=_word_pbuz2 +Succesfully loaded fragment pbuz1=_inc_pbuz1 +Attempting fragment synthesis pbuz1_lt_pbuc1_then_la1 +Succesfully loaded fragment pbuz1_lt_vwuc1_then_la1 +Succesfully synthesized fragment pbuz1_lt_pbuc1_then_la1 (from pbuz1_lt_vwuc1_then_la1) +Attempting fragment synthesis vbuz1=_hi_vwuz2 +Succesfully loaded fragment vbuaa=_hi_vwuz1 +Succesfully synthesized fragment vbuz1=_hi_vwuz2 (from vbuaa=_hi_vwuz1) +Attempting fragment synthesis vbuz1=_lo_vwuz2 +Succesfully loaded fragment vbuaa=_lo_vwuz1 +Succesfully synthesized fragment vbuz1=_lo_vwuz2 (from vbuaa=_lo_vwuz1) +Attempting fragment synthesis vbuz1=vbuz2_ror_4 +Attempting fragment synthesis vbuaa=vbuz1_ror_4 +Succesfully loaded fragment vbuaa=vbuaa_ror_4 +Succesfully synthesized fragment vbuaa=vbuz1_ror_4 (from vbuaa=vbuaa_ror_4) +Succesfully synthesized fragment vbuz1=vbuz2_ror_4 (from vbuaa=vbuz1_ror_4) +Attempting fragment synthesis vbuz1=pbuc1_derefidx_vbuz2 +Attempting fragment synthesis vbuz1=vwuc1_derefidx_vbuz2 +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuz1 +Succesfully synthesized fragment vbuz1=vwuc1_derefidx_vbuz2 (from vbuaa=vwuc1_derefidx_vbuz1) +Succesfully synthesized fragment vbuz1=pbuc1_derefidx_vbuz2 (from vbuz1=vwuc1_derefidx_vbuz2) +Attempting fragment synthesis vbuz1=vbuz2_band_vbuc1 +Attempting fragment synthesis vbuaa=vbuz1_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuaa=vbuz1_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Succesfully synthesized fragment vbuz1=vbuz2_band_vbuc1 (from vbuaa=vbuz1_band_vbuc1) +Succesfully loaded fragment _deref_pbuz1=vbuz2 +Attempting fragment synthesis _deref_pbuz1_neq_vbuc1_then_la1 +Succesfully loaded fragment vbuaa_neq_vbuc1_then_la1 +Succesfully synthesized fragment _deref_pbuz1_neq_vbuc1_then_la1 (from vbuaa_neq_vbuc1_then_la1) +Attempting fragment synthesis _deref_pbuz1=_deref_pbuz2 +Succesfully loaded fragment vbuaa=_deref_pbuz1 +Succesfully synthesized fragment _deref_pbuz1=_deref_pbuz2 (from vbuaa=_deref_pbuz1) +Succesfully loaded fragment _deref_pbuz1=vbuc1 +Succesfully loaded fragment pbuz1_neq_vwuc1_then_la1 +Attempting fragment synthesis _deref_pbuc1=_deref_pbuc2 +Attempting fragment synthesis _deref_pbuc1=_deref_vwuc2 +Attempting fragment synthesis _deref_vwuc1=_deref_vwuc2 +Succesfully loaded fragment vbuaa=_deref_vwuc1 +Succesfully synthesized fragment _deref_vwuc1=_deref_vwuc2 (from vbuaa=_deref_vwuc1) +Succesfully synthesized fragment _deref_pbuc1=_deref_vwuc2 (from _deref_vwuc1=_deref_vwuc2) +Succesfully synthesized fragment _deref_pbuc1=_deref_pbuc2 (from _deref_pbuc1=_deref_vwuc2) +Attempting fragment synthesis vbuz1=vbuc1 +Succesfully loaded fragment vbuaa=vbuc1 +Succesfully synthesized fragment vbuz1=vbuc1 (from vbuaa=vbuc1) +Attempting fragment synthesis vwuz1=vbuc1 +Succesfully loaded fragment vwuz1=vbuaa +Succesfully synthesized fragment vwuz1=vbuc1 (from vwuz1=vbuaa) +Succesfully loaded fragment vbuz1=_inc_vbuz1 +Succesfully loaded fragment vbuz1_neq_0_then_la1 +Succesfully loaded fragment vwuz1=_inc_vwuz1 +Attempting fragment synthesis vwuz1=vwuz1_plus_vbuz2 +Attempting fragment synthesis vwuz1=vwuz1_plus_vbuaa +Succesfully loaded fragment vwuz1=vbuaa_plus_vwuz1 +Succesfully synthesized fragment vwuz1=vwuz1_plus_vbuaa (from vwuz1=vbuaa_plus_vwuz1) +Succesfully synthesized fragment vwuz1=vwuz1_plus_vbuz2 (from vwuz1=vwuz1_plus_vbuaa) +Attempting fragment synthesis pbuz1_neq_pbuc1_then_la1 +Succesfully loaded fragment pbuz1_neq_vwuc1_then_la1 +Succesfully synthesized fragment pbuz1_neq_pbuc1_then_la1 (from pbuz1_neq_vwuc1_then_la1) +Attempting fragment synthesis _deref_pbuz1=pbuc1_derefidx_vbuz2 +Attempting fragment synthesis _deref_pbuz1=vwuc1_derefidx_vbuz2 +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuz1 +Succesfully synthesized fragment _deref_pbuz1=vwuc1_derefidx_vbuz2 (from vbuaa=vwuc1_derefidx_vbuz1) +Succesfully synthesized fragment _deref_pbuz1=pbuc1_derefidx_vbuz2 (from _deref_pbuz1=vwuc1_derefidx_vbuz2) +Succesfully loaded fragment vbuz1=vbuz1_plus_vbuz2 INITIAL ASM //SEG0 Basic Upstart @@ -1039,30 +2307,35 @@ INITIAL ASM .pc = $80d "Program" //SEG1 Global Constants & labels .const BGCOL = $d021 - mul_sqr_lo: .fill 512, 0 - mul_sqr_hi: .fill 512, 0 - asm_mul_sqr_lo: .fill 512, 0 - asm_mul_sqr_hi: .fill 512, 0 + .label char_cursor = $a + mul_sqr1_lo: .fill 512, 0 + mul_sqr1_hi: .fill 512, 0 + mul_sqr2_lo: .fill 512, 0 + mul_sqr2_hi: .fill 512, 0 + asm_mul_sqr1_lo: .fill 512, 0 + asm_mul_sqr1_hi: .fill 512, 0 + asm_mul_sqr2_lo: .fill 512, 0 + asm_mul_sqr2_hi: .fill 512, 0 //SEG2 @begin bbegin: -//SEG3 [1] phi from @begin to @4 [phi:@begin->@4] -b4_from_bbegin: - jmp b4 -//SEG4 @4 -b4: +//SEG3 [1] phi from @begin to @10 [phi:@begin->@10] +b10_from_bbegin: + jmp b10 +//SEG4 @10 +b10: //SEG5 [2] call main param-assignment [ ] ( ) -//SEG6 [4] phi from @4 to main [phi:@4->main] -main_from_b4: +//SEG6 [4] phi from @10 to main [phi:@10->main] +main_from_b10: jsr main -//SEG7 [3] phi from @4 to @end [phi:@4->@end] -bend_from_b4: +//SEG7 [3] phi from @10 to @end [phi:@10->@end] +bend_from_b10: jmp bend //SEG8 @end bend: //SEG9 main main: { //SEG10 [5] call init_mul_tables param-assignment [ ] ( main:2 [ ] ) - //SEG11 [26] phi from main to init_mul_tables [phi:main->init_mul_tables] + //SEG11 [66] phi from main to init_mul_tables [phi:main->init_mul_tables] init_mul_tables_from_main: jsr init_mul_tables //SEG12 [6] phi from main to main::@1 [phi:main->main::@1] @@ -1087,92 +2360,324 @@ main: { } //SEG20 mul_tables_compare mul_tables_compare: { - .label i = 2 + .label asm_sqr = 4 + .label kc_sqr = 2 //SEG21 [11] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 5 [ ] ( main:2::mul_tables_compare:9 [ ] ) -- _deref_pbuc1=vbuc2 lda #5 sta BGCOL //SEG22 [12] phi from mul_tables_compare to mul_tables_compare::@1 [phi:mul_tables_compare->mul_tables_compare::@1] b1_from_mul_tables_compare: - //SEG23 [12] phi (byte) mul_tables_compare::i#10 = (byte/signed byte/word/signed word) 0 [phi:mul_tables_compare->mul_tables_compare::@1#0] -- vbuz1=vbuc1 - lda #0 - sta i + //SEG23 [12] phi (byte*) mul_tables_compare::asm_sqr#2 = (const byte[512]) asm_mul_sqr1_lo#0 [phi:mul_tables_compare->mul_tables_compare::@1#0] -- pbuz1=pbuc1 + lda #asm_mul_sqr1_lo + sta asm_sqr+1 + //SEG24 [12] phi (byte*) mul_tables_compare::kc_sqr#2 = (const byte[512]) mul_sqr1_lo#0 [phi:mul_tables_compare->mul_tables_compare::@1#1] -- pbuz1=pbuc1 + lda #mul_sqr1_lo + sta kc_sqr+1 jmp b1 - //SEG24 [12] phi from mul_tables_compare::@5 to mul_tables_compare::@1 [phi:mul_tables_compare::@5->mul_tables_compare::@1] - b1_from_b5: - //SEG25 [12] phi (byte) mul_tables_compare::i#10 = (byte) mul_tables_compare::i#1 [phi:mul_tables_compare::@5->mul_tables_compare::@1#0] -- register_copy + //SEG25 [12] phi from mul_tables_compare::@2 to mul_tables_compare::@1 [phi:mul_tables_compare::@2->mul_tables_compare::@1] + b1_from_b2: + //SEG26 [12] phi (byte*) mul_tables_compare::asm_sqr#2 = (byte*) mul_tables_compare::asm_sqr#1 [phi:mul_tables_compare::@2->mul_tables_compare::@1#0] -- register_copy + //SEG27 [12] phi (byte*) mul_tables_compare::kc_sqr#2 = (byte*) mul_tables_compare::kc_sqr#1 [phi:mul_tables_compare::@2->mul_tables_compare::@1#1] -- register_copy jmp b1 - //SEG26 mul_tables_compare::@1 + //SEG28 mul_tables_compare::@1 b1: - //SEG27 [13] if(*((const byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- pbuc1_derefidx_vbuz1_eq_pbuc2_derefidx_vbuz1_then_la1 - lda mul_sqr_lo,x - cmp asm_mul_sqr_lo,x + //SEG29 [13] if(*((byte*) mul_tables_compare::kc_sqr#2)==*((byte*) mul_tables_compare::asm_sqr#2)) goto mul_tables_compare::@2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) -- _deref_pbuz1_eq__deref_pbuz2_then_la1 + ldy #0 + lda (kc_sqr),y + ldy #0 + cmp (asm_sqr),y beq b2 - ldx i - jmp b6 - //SEG28 mul_tables_compare::@6 - b6: - //SEG29 [14] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- _deref_pbuc1=vbuc2 - lda #2 - sta BGCOL - jmp b2 - //SEG30 mul_tables_compare::@2 - b2: - //SEG31 [15] if(*((const byte[512]) mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@3 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- pbuc1_derefidx_vbuz1_eq_pbuc2_derefidx_vbuz1_then_la1 - lda mul_sqr_hi+$100,x - cmp asm_mul_sqr_hi+$100,x - beq b3 - ldx i - jmp b7 - //SEG32 mul_tables_compare::@7 - b7: - //SEG33 [16] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- _deref_pbuc1=vbuc2 - lda #2 - sta BGCOL jmp b3 - //SEG34 mul_tables_compare::@3 + //SEG30 mul_tables_compare::@3 b3: - //SEG35 [17] if(*((const byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@4 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- pbuc1_derefidx_vbuz1_eq_pbuc2_derefidx_vbuz1_then_la1 - lda mul_sqr_lo,x - cmp asm_mul_sqr_lo,x - beq b4 - ldx i + //SEG31 [14] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) -- _deref_pbuc1=vbuc2 + lda #2 + sta BGCOL + //SEG32 [15] call print_cls param-assignment [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) + //SEG33 [54] phi from mul_tables_compare::@3 to print_cls [phi:mul_tables_compare::@3->print_cls] + print_cls_from_b3: + jsr print_cls + //SEG34 [16] phi from mul_tables_compare::@3 to mul_tables_compare::@6 [phi:mul_tables_compare::@3->mul_tables_compare::@6] + b6_from_b3: + jmp b6 + //SEG35 mul_tables_compare::@6 + b6: + //SEG36 [17] call print_str param-assignment [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 ] ) + //SEG37 [47] phi from mul_tables_compare::@6 to print_str [phi:mul_tables_compare::@6->print_str] + print_str_from_b6: + //SEG38 [47] phi (byte*) char_cursor#44 = ((byte*))(word/signed word) 1024 [phi:mul_tables_compare::@6->print_str#0] -- pbuz1=pbuc1 + lda #<$400 + sta char_cursor + lda #>$400 + sta char_cursor+1 + //SEG39 [47] phi (byte*) print_str::str#5 = (const string) mul_tables_compare::str [phi:mul_tables_compare::@6->print_str#1] -- pbuz1=pbuc1 + lda #str + sta print_str.str+1 + jsr print_str + jmp b7 + //SEG40 mul_tables_compare::@7 + b7: + //SEG41 [18] (word) print_word::w#0 ← ((word)) (byte*) mul_tables_compare::asm_sqr#2 [ mul_tables_compare::kc_sqr#2 print_word::w#0 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 print_word::w#0 char_cursor#19 ] ) -- vwuz1=_word_pbuz2 + lda asm_sqr + sta print_word.w + lda asm_sqr+1 + sta print_word.w+1 + //SEG42 [19] call print_word param-assignment [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] ) + //SEG43 [29] phi from mul_tables_compare::@7 to print_word [phi:mul_tables_compare::@7->print_word] + print_word_from_b7: + //SEG44 [29] phi (word) print_word::w#2 = (word) print_word::w#0 [phi:mul_tables_compare::@7->print_word#0] -- register_copy + jsr print_word + //SEG45 [20] phi from mul_tables_compare::@7 to mul_tables_compare::@8 [phi:mul_tables_compare::@7->mul_tables_compare::@8] + b8_from_b7: jmp b8 - //SEG36 mul_tables_compare::@8 + //SEG46 mul_tables_compare::@8 b8: - //SEG37 [18] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- _deref_pbuc1=vbuc2 - lda #2 - sta BGCOL - jmp b4 - //SEG38 mul_tables_compare::@4 - b4: - //SEG39 [19] if(*((const byte[512]) mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@5 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- pbuc1_derefidx_vbuz1_eq_pbuc2_derefidx_vbuz1_then_la1 - lda mul_sqr_hi+$100,x - cmp asm_mul_sqr_hi+$100,x - beq b5 - ldx i + //SEG47 [21] call print_str param-assignment [ mul_tables_compare::kc_sqr#2 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 char_cursor#19 ] ) + //SEG48 [47] phi from mul_tables_compare::@8 to print_str [phi:mul_tables_compare::@8->print_str] + print_str_from_b8: + //SEG49 [47] phi (byte*) char_cursor#44 = (byte*) char_cursor#10 [phi:mul_tables_compare::@8->print_str#0] -- register_copy + //SEG50 [47] phi (byte*) print_str::str#5 = (const string) mul_tables_compare::str1 [phi:mul_tables_compare::@8->print_str#1] -- pbuz1=pbuc1 + lda #str1 + sta print_str.str+1 + jsr print_str jmp b9 - //SEG40 mul_tables_compare::@9 + //SEG51 mul_tables_compare::@9 b9: - //SEG41 [20] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- _deref_pbuc1=vbuc2 - lda #2 - sta BGCOL - jmp b5 - //SEG42 mul_tables_compare::@5 - b5: - //SEG43 [21] (byte) mul_tables_compare::i#1 ← ++ (byte) mul_tables_compare::i#10 [ mul_tables_compare::i#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#1 ] ) -- vbuz1=_inc_vbuz1 - inc i - //SEG44 [22] if((byte) mul_tables_compare::i#1!=(byte/signed byte/word/signed word) 0) goto mul_tables_compare::@1 [ mul_tables_compare::i#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#1 ] ) -- vbuz1_neq_0_then_la1 - lda i - bne b1_from_b5 + //SEG52 [22] (word) print_word::w#1 ← ((word)) (byte*) mul_tables_compare::kc_sqr#2 [ print_word::w#1 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ print_word::w#1 char_cursor#19 ] ) -- vwuz1=_word_pbuz2 + lda kc_sqr + sta print_word.w + lda kc_sqr+1 + sta print_word.w+1 + //SEG53 [23] call print_word param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9 [ char_cursor#10 ] ) + //SEG54 [29] phi from mul_tables_compare::@9 to print_word [phi:mul_tables_compare::@9->print_word] + print_word_from_b9: + //SEG55 [29] phi (word) print_word::w#2 = (word) print_word::w#1 [phi:mul_tables_compare::@9->print_word#0] -- register_copy + jsr print_word + //SEG56 [24] phi from mul_tables_compare::@9 to mul_tables_compare::@return [phi:mul_tables_compare::@9->mul_tables_compare::@return] + breturn_from_b9: + //SEG57 [24] phi (byte*) char_cursor#17 = (byte*) char_cursor#10 [phi:mul_tables_compare::@9->mul_tables_compare::@return#0] -- register_copy jmp breturn - //SEG45 mul_tables_compare::@return + //SEG58 mul_tables_compare::@return breturn: - //SEG46 [23] return [ ] ( main:2::mul_tables_compare:9 [ ] ) + //SEG59 [25] return [ ] ( main:2::mul_tables_compare:9 [ ] ) + rts + //SEG60 mul_tables_compare::@2 + b2: + //SEG61 [26] (byte*) mul_tables_compare::asm_sqr#1 ← ++ (byte*) mul_tables_compare::asm_sqr#2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#1 ] ) -- pbuz1=_inc_pbuz1 + inc asm_sqr + bne !+ + inc asm_sqr+1 + !: + //SEG62 [27] (byte*) mul_tables_compare::kc_sqr#1 ← ++ (byte*) mul_tables_compare::kc_sqr#2 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ) -- pbuz1=_inc_pbuz1 + inc kc_sqr + bne !+ + inc kc_sqr+1 + !: + //SEG63 [28] if((byte*) mul_tables_compare::kc_sqr#1<(const byte[512]) mul_sqr1_lo#0+(word/signed word) 512*(byte/signed byte/word/signed word) 4) goto mul_tables_compare::@1 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ) -- pbuz1_lt_pbuc1_then_la1 + lda kc_sqr+1 + cmp #>mul_sqr1_lo+$200*4 + bcc b1_from_b2 + bne !+ + lda kc_sqr + cmp #mul_tables_compare::@return] + breturn_from_b2: + //SEG65 [24] phi (byte*) char_cursor#17 = ((byte*))(word/signed word) 1024 [phi:mul_tables_compare::@2->mul_tables_compare::@return#0] -- pbuz1=pbuc1 + lda #<$400 + sta char_cursor + lda #>$400 + sta char_cursor+1 + jmp breturn + str: .text "mul table mismatch at @" + str1: .text " / @" +} +//SEG66 print_word +print_word: { + .label w = 6 + //SEG67 [30] (byte) print_byte::b#0 ← > (word) print_word::w#2 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#0 char_cursor#19 ] main:2::mul_tables_compare:9::print_word:23 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ) -- vbuz1=_hi_vwuz2 + lda w+1 + sta print_byte.b + //SEG68 [31] call print_byte param-assignment [ char_cursor#10 print_word::w#2 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_word::w#2 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 print_word::w#2 ] ) + //SEG69 [35] phi from print_word to print_byte [phi:print_word->print_byte] + print_byte_from_print_word: + //SEG70 [35] phi (byte*) char_cursor#39 = (byte*) char_cursor#19 [phi:print_word->print_byte#0] -- register_copy + //SEG71 [35] phi (byte) print_byte::b#2 = (byte) print_byte::b#0 [phi:print_word->print_byte#1] -- register_copy + jsr print_byte + jmp b1 + //SEG72 print_word::@1 + b1: + //SEG73 [32] (byte) print_byte::b#1 ← < (word) print_word::w#2 [ char_cursor#10 print_byte::b#1 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::b#1 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 print_byte::b#1 ] ) -- vbuz1=_lo_vwuz2 + lda w + sta print_byte.b + //SEG74 [33] call print_byte param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 ] ) + //SEG75 [35] phi from print_word::@1 to print_byte [phi:print_word::@1->print_byte] + print_byte_from_b1: + //SEG76 [35] phi (byte*) char_cursor#39 = (byte*) char_cursor#10 [phi:print_word::@1->print_byte#0] -- register_copy + //SEG77 [35] phi (byte) print_byte::b#2 = (byte) print_byte::b#1 [phi:print_word::@1->print_byte#1] -- register_copy + jsr print_byte + jmp breturn + //SEG78 print_word::@return + breturn: + //SEG79 [34] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 ] ) rts } -//SEG47 init_mul_tables_asm +//SEG80 print_byte +print_byte: { + .label _0 = $1e + .label _2 = $1f + .label b = 8 + //SEG81 [36] (byte~) print_byte::$0 ← (byte) print_byte::b#2 >> (byte/signed byte/word/signed word) 4 [ print_byte::b#2 char_cursor#39 print_byte::$0 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 print_byte::$0 ] ) -- vbuz1=vbuz2_ror_4 + lda b + lsr + lsr + lsr + lsr + sta _0 + //SEG82 [37] (byte) print_char::ch#0 ← *((const byte[]) print_byte::hextab#0 + (byte~) print_byte::$0) [ print_byte::b#2 char_cursor#39 print_char::ch#0 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 print_char::ch#0 ] ) -- vbuz1=pbuc1_derefidx_vbuz2 + ldx _0 + lda hextab,x + sta print_char.ch + //SEG83 [38] call print_char param-assignment [ char_cursor#10 print_byte::b#2 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_byte::b#2 ] ) + //SEG84 [43] phi from print_byte to print_char [phi:print_byte->print_char] + print_char_from_print_byte: + //SEG85 [43] phi (byte*) char_cursor#27 = (byte*) char_cursor#39 [phi:print_byte->print_char#0] -- register_copy + //SEG86 [43] phi (byte) print_char::ch#2 = (byte) print_char::ch#0 [phi:print_byte->print_char#1] -- register_copy + jsr print_char + jmp b1 + //SEG87 print_byte::@1 + b1: + //SEG88 [39] (byte~) print_byte::$2 ← (byte) print_byte::b#2 & (byte/signed byte/word/signed word) 15 [ char_cursor#10 print_byte::$2 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_byte::$2 ] ) -- vbuz1=vbuz2_band_vbuc1 + lda b + and #$f + sta _2 + //SEG89 [40] (byte) print_char::ch#1 ← *((const byte[]) print_byte::hextab#0 + (byte~) print_byte::$2) [ char_cursor#10 print_char::ch#1 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_char::ch#1 ] ) -- vbuz1=pbuc1_derefidx_vbuz2 + ldx _2 + lda hextab,x + sta print_char.ch + //SEG90 [41] call print_char param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 ] ) + //SEG91 [43] phi from print_byte::@1 to print_char [phi:print_byte::@1->print_char] + print_char_from_b1: + //SEG92 [43] phi (byte*) char_cursor#27 = (byte*) char_cursor#10 [phi:print_byte::@1->print_char#0] -- register_copy + //SEG93 [43] phi (byte) print_char::ch#2 = (byte) print_char::ch#1 [phi:print_byte::@1->print_char#1] -- register_copy + jsr print_char + jmp breturn + //SEG94 print_byte::@return + breturn: + //SEG95 [42] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 ] ) + rts + hextab: .byte '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f' +} +//SEG96 print_char +print_char: { + .label ch = 9 + //SEG97 [44] *((byte*) char_cursor#27) ← (byte) print_char::ch#2 [ char_cursor#27 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#27 ] ) -- _deref_pbuz1=vbuz2 + ldy #0 + lda ch + sta (char_cursor),y + //SEG98 [45] (byte*) char_cursor#10 ← ++ (byte*) char_cursor#27 [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#10 ] ) -- pbuz1=_inc_pbuz1 + inc char_cursor + bne !+ + inc char_cursor+1 + !: + jmp breturn + //SEG99 print_char::@return + breturn: + //SEG100 [46] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#10 ] ) + rts +} +//SEG101 print_str +print_str: { + .label str = $c + //SEG102 [48] phi from print_str print_str::@2 to print_str::@1 [phi:print_str/print_str::@2->print_str::@1] + b1_from_print_str: + b1_from_b2: + //SEG103 [48] phi (byte*) char_cursor#19 = (byte*) char_cursor#44 [phi:print_str/print_str::@2->print_str::@1#0] -- register_copy + //SEG104 [48] phi (byte*) print_str::str#3 = (byte*) print_str::str#5 [phi:print_str/print_str::@2->print_str::@1#1] -- register_copy + jmp b1 + //SEG105 print_str::@1 + b1: + //SEG106 [49] if(*((byte*) print_str::str#3)!=(byte) '@') goto print_str::@2 [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) -- _deref_pbuz1_neq_vbuc1_then_la1 + ldy #0 + lda (str),y + cmp #'@' + bne b2 + jmp breturn + //SEG107 print_str::@return + breturn: + //SEG108 [50] return [ char_cursor#19 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 ] ) + rts + //SEG109 print_str::@2 + b2: + //SEG110 [51] *((byte*) char_cursor#19) ← *((byte*) print_str::str#3) [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) -- _deref_pbuz1=_deref_pbuz2 + ldy #0 + lda (str),y + ldy #0 + sta (char_cursor),y + //SEG111 [52] (byte*) char_cursor#1 ← ++ (byte*) char_cursor#19 [ print_str::str#3 char_cursor#1 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#3 char_cursor#1 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#3 char_cursor#1 ] ) -- pbuz1=_inc_pbuz1 + inc char_cursor + bne !+ + inc char_cursor+1 + !: + //SEG112 [53] (byte*) print_str::str#0 ← ++ (byte*) print_str::str#3 [ print_str::str#0 char_cursor#1 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#0 char_cursor#1 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#0 char_cursor#1 ] ) -- pbuz1=_inc_pbuz1 + inc str + bne !+ + inc str+1 + !: + jmp b1_from_b2 +} +//SEG113 print_cls +print_cls: { + .label sc = $e + //SEG114 [55] phi from print_cls to print_cls::@1 [phi:print_cls->print_cls::@1] + b1_from_print_cls: + //SEG115 [55] phi (byte*) print_cls::sc#2 = ((byte*))(word/signed word) 1024 [phi:print_cls->print_cls::@1#0] -- pbuz1=pbuc1 + lda #<$400 + sta sc + lda #>$400 + sta sc+1 + jmp b1 + //SEG116 [55] phi from print_cls::@1 to print_cls::@1 [phi:print_cls::@1->print_cls::@1] + b1_from_b1: + //SEG117 [55] phi (byte*) print_cls::sc#2 = (byte*) print_cls::sc#1 [phi:print_cls::@1->print_cls::@1#0] -- register_copy + jmp b1 + //SEG118 print_cls::@1 + b1: + //SEG119 [56] *((byte*) print_cls::sc#2) ← (byte) ' ' [ print_cls::sc#2 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#2 ] ) -- _deref_pbuz1=vbuc1 + ldy #0 + lda #' ' + sta (sc),y + //SEG120 [57] (byte*) print_cls::sc#1 ← ++ (byte*) print_cls::sc#2 [ print_cls::sc#1 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#1 ] ) -- pbuz1=_inc_pbuz1 + inc sc + bne !+ + inc sc+1 + !: + //SEG121 [58] if((byte*) print_cls::sc#1!=(word/signed word) 1024+(word/signed word) 1000) goto print_cls::@1 [ print_cls::sc#1 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#1 ] ) -- pbuz1_neq_vwuc1_then_la1 + lda sc+1 + cmp #>$400+$3e8 + bne b1_from_b1 + lda sc + cmp #<$400+$3e8 + bne b1_from_b1 + jmp breturn + //SEG122 print_cls::@return + breturn: + //SEG123 [59] return [ ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) + rts +} +//SEG124 init_mul_tables_asm init_mul_tables_asm: { - //SEG48 asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr_lo,xbnelb1incml0+2incml1+2clcinybnelb1 } + .const mem = $ff + //SEG125 asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr1_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr1_lo,xbnelb1incml0+2incml1+2clcinybnelb1ldx#$00ldy#$ff!:ldaasm_mul_sqr1_hi+1,xstaasm_mul_sqr2_hi+$100,xldaasm_mul_sqr1_hi,xstaasm_mul_sqr2_hi,yldaasm_mul_sqr1_lo+1,xstaasm_mul_sqr2_lo+$100,xldaasm_mul_sqr1_lo,xstaasm_mul_sqr2_lo,ydeyinxbne!- } ldx #0 txa .byte $c9 @@ -1180,7 +2685,7 @@ init_mul_tables_asm: { tya adc #0 ml1: - sta asm_mul_sqr_hi,x + sta asm_mul_sqr1_hi,x tay cmp #$40 txa @@ -1190,110 +2695,140 @@ init_mul_tables_asm: { sta ml9+1 inx ml0: - sta asm_mul_sqr_lo,x + sta asm_mul_sqr1_lo,x bne lb1 inc ml0+2 inc ml1+2 clc iny bne lb1 + ldx #0 + ldy #$ff + !: + lda asm_mul_sqr1_hi+1,x + sta asm_mul_sqr2_hi+$100,x + lda asm_mul_sqr1_hi,x + sta asm_mul_sqr2_hi,y + lda asm_mul_sqr1_lo+1,x + sta asm_mul_sqr2_lo+$100,x + lda asm_mul_sqr1_lo,x + sta asm_mul_sqr2_lo,y + dey + inx + bne !- + //SEG126 [61] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) -- _deref_pbuc1=_deref_pbuc2 + lda asm_mul_sqr1_lo + sta mem + //SEG127 [62] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) -- _deref_pbuc1=_deref_pbuc2 + lda asm_mul_sqr1_hi + sta mem + //SEG128 [63] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) -- _deref_pbuc1=_deref_pbuc2 + lda asm_mul_sqr2_lo + sta mem + //SEG129 [64] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) -- _deref_pbuc1=_deref_pbuc2 + lda asm_mul_sqr2_hi + sta mem jmp breturn - //SEG49 init_mul_tables_asm::@return + //SEG130 init_mul_tables_asm::@return breturn: - //SEG50 [25] return [ ] ( main:2::init_mul_tables_asm:7 [ ] ) + //SEG131 [65] return [ ] ( main:2::init_mul_tables_asm:7 [ ] ) rts } -//SEG51 init_mul_tables +//SEG132 init_mul_tables init_mul_tables: { - .label _2 = $b - .label _5 = $c - .label _6 = $d - .label c = 3 - .label sqr_hi = 6 - .label sqr = 9 - .label sqr_lo = 4 - .label x_2 = 8 - //SEG52 [27] phi from init_mul_tables to init_mul_tables::@1 [phi:init_mul_tables->init_mul_tables::@1] + .label _2 = $20 + .label _5 = $21 + .label _6 = $22 + .label c = $10 + .label sqr1_hi = $13 + .label sqr = $16 + .label sqr1_lo = $11 + .label x_2 = $15 + .label sqr2_hi = $1b + .label x_255 = $18 + .label sqr2_lo = $19 + .label dir = $1d + //SEG133 [67] phi from init_mul_tables to init_mul_tables::@1 [phi:init_mul_tables->init_mul_tables::@1] b1_from_init_mul_tables: - //SEG53 [27] phi (byte) init_mul_tables::x_2#3 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#0] -- vbuz1=vbuc1 + //SEG134 [67] phi (byte) init_mul_tables::x_2#3 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#0] -- vbuz1=vbuc1 lda #0 sta x_2 - //SEG54 [27] phi (byte*) init_mul_tables::sqr_hi#2 = (const byte[512]) mul_sqr_hi#0+(byte/signed byte/word/signed word) 1 [phi:init_mul_tables->init_mul_tables::@1#1] -- pbuz1=pbuc1 - lda #mul_sqr_hi+1 - sta sqr_hi+1 - //SEG55 [27] phi (byte*) init_mul_tables::sqr_lo#2 = (const byte[512]) mul_sqr_lo#0+(byte/signed byte/word/signed word) 1 [phi:init_mul_tables->init_mul_tables::@1#2] -- pbuz1=pbuc1 - lda #mul_sqr_lo+1 - sta sqr_lo+1 - //SEG56 [27] phi (word) init_mul_tables::sqr#4 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#3] -- vwuz1=vbuc1 + //SEG135 [67] phi (byte*) init_mul_tables::sqr1_hi#2 = (const byte[512]) mul_sqr1_hi#0+(byte/signed byte/word/signed word) 1 [phi:init_mul_tables->init_mul_tables::@1#1] -- pbuz1=pbuc1 + lda #mul_sqr1_hi+1 + sta sqr1_hi+1 + //SEG136 [67] phi (byte*) init_mul_tables::sqr1_lo#2 = (const byte[512]) mul_sqr1_lo#0+(byte/signed byte/word/signed word) 1 [phi:init_mul_tables->init_mul_tables::@1#2] -- pbuz1=pbuc1 + lda #mul_sqr1_lo+1 + sta sqr1_lo+1 + //SEG137 [67] phi (word) init_mul_tables::sqr#4 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#3] -- vwuz1=vbuc1 lda #0 sta sqr lda #0 sta sqr+1 - //SEG57 [27] phi (byte) init_mul_tables::c#2 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#4] -- vbuz1=vbuc1 + //SEG138 [67] phi (byte) init_mul_tables::c#2 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#4] -- vbuz1=vbuc1 lda #0 sta c jmp b1 - //SEG58 [27] phi from init_mul_tables::@2 to init_mul_tables::@1 [phi:init_mul_tables::@2->init_mul_tables::@1] + //SEG139 [67] phi from init_mul_tables::@2 to init_mul_tables::@1 [phi:init_mul_tables::@2->init_mul_tables::@1] b1_from_b2: - //SEG59 [27] phi (byte) init_mul_tables::x_2#3 = (byte) init_mul_tables::x_2#2 [phi:init_mul_tables::@2->init_mul_tables::@1#0] -- register_copy - //SEG60 [27] phi (byte*) init_mul_tables::sqr_hi#2 = (byte*) init_mul_tables::sqr_hi#1 [phi:init_mul_tables::@2->init_mul_tables::@1#1] -- register_copy - //SEG61 [27] phi (byte*) init_mul_tables::sqr_lo#2 = (byte*) init_mul_tables::sqr_lo#1 [phi:init_mul_tables::@2->init_mul_tables::@1#2] -- register_copy - //SEG62 [27] phi (word) init_mul_tables::sqr#4 = (word) init_mul_tables::sqr#1 [phi:init_mul_tables::@2->init_mul_tables::@1#3] -- register_copy - //SEG63 [27] phi (byte) init_mul_tables::c#2 = (byte) init_mul_tables::c#1 [phi:init_mul_tables::@2->init_mul_tables::@1#4] -- register_copy + //SEG140 [67] phi (byte) init_mul_tables::x_2#3 = (byte) init_mul_tables::x_2#2 [phi:init_mul_tables::@2->init_mul_tables::@1#0] -- register_copy + //SEG141 [67] phi (byte*) init_mul_tables::sqr1_hi#2 = (byte*) init_mul_tables::sqr1_hi#1 [phi:init_mul_tables::@2->init_mul_tables::@1#1] -- register_copy + //SEG142 [67] phi (byte*) init_mul_tables::sqr1_lo#2 = (byte*) init_mul_tables::sqr1_lo#1 [phi:init_mul_tables::@2->init_mul_tables::@1#2] -- register_copy + //SEG143 [67] phi (word) init_mul_tables::sqr#4 = (word) init_mul_tables::sqr#1 [phi:init_mul_tables::@2->init_mul_tables::@1#3] -- register_copy + //SEG144 [67] phi (byte) init_mul_tables::c#2 = (byte) init_mul_tables::c#1 [phi:init_mul_tables::@2->init_mul_tables::@1#4] -- register_copy jmp b1 - //SEG64 init_mul_tables::@1 + //SEG145 init_mul_tables::@1 b1: - //SEG65 [28] (byte) init_mul_tables::c#1 ← ++ (byte) init_mul_tables::c#2 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) -- vbuz1=_inc_vbuz1 + //SEG146 [68] (byte) init_mul_tables::c#1 ← ++ (byte) init_mul_tables::c#2 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) -- vbuz1=_inc_vbuz1 inc c - //SEG66 [29] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) -- vbuz1=vbuz2_band_vbuc1 + //SEG147 [69] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) -- vbuz1=vbuz2_band_vbuc1 lda c and #1 sta _2 - //SEG67 [30] if((byte~) init_mul_tables::$2!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@2 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) -- vbuz1_neq_0_then_la1 + //SEG148 [70] if((byte~) init_mul_tables::$2!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@2 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) -- vbuz1_neq_0_then_la1 lda _2 bne b2_from_b1 - jmp b3 - //SEG68 init_mul_tables::@3 - b3: - //SEG69 [31] (byte) init_mul_tables::x_2#1 ← ++ (byte) init_mul_tables::x_2#3 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ) -- vbuz1=_inc_vbuz1 + jmp b5 + //SEG149 init_mul_tables::@5 + b5: + //SEG150 [71] (byte) init_mul_tables::x_2#1 ← ++ (byte) init_mul_tables::x_2#3 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ) -- vbuz1=_inc_vbuz1 inc x_2 - //SEG70 [32] (word) init_mul_tables::sqr#2 ← ++ (word) init_mul_tables::sqr#4 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ) -- vwuz1=_inc_vwuz1 + //SEG151 [72] (word) init_mul_tables::sqr#2 ← ++ (word) init_mul_tables::sqr#4 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ) -- vwuz1=_inc_vwuz1 inc sqr bne !+ inc sqr+1 !: - //SEG71 [33] phi from init_mul_tables::@1 init_mul_tables::@3 to init_mul_tables::@2 [phi:init_mul_tables::@1/init_mul_tables::@3->init_mul_tables::@2] + //SEG152 [73] phi from init_mul_tables::@1 init_mul_tables::@5 to init_mul_tables::@2 [phi:init_mul_tables::@1/init_mul_tables::@5->init_mul_tables::@2] b2_from_b1: - b2_from_b3: - //SEG72 [33] phi (byte) init_mul_tables::x_2#2 = (byte) init_mul_tables::x_2#3 [phi:init_mul_tables::@1/init_mul_tables::@3->init_mul_tables::@2#0] -- register_copy - //SEG73 [33] phi (word) init_mul_tables::sqr#3 = (word) init_mul_tables::sqr#4 [phi:init_mul_tables::@1/init_mul_tables::@3->init_mul_tables::@2#1] -- register_copy + b2_from_b5: + //SEG153 [73] phi (byte) init_mul_tables::x_2#2 = (byte) init_mul_tables::x_2#3 [phi:init_mul_tables::@1/init_mul_tables::@5->init_mul_tables::@2#0] -- register_copy + //SEG154 [73] phi (word) init_mul_tables::sqr#3 = (word) init_mul_tables::sqr#4 [phi:init_mul_tables::@1/init_mul_tables::@5->init_mul_tables::@2#1] -- register_copy jmp b2 - //SEG74 init_mul_tables::@2 + //SEG155 init_mul_tables::@2 b2: - //SEG75 [34] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) -- vbuz1=_lo_vwuz2 + //SEG156 [74] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) -- vbuz1=_lo_vwuz2 lda sqr sta _5 - //SEG76 [35] *((byte*) init_mul_tables::sqr_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- _deref_pbuz1=vbuz2 + //SEG157 [75] *((byte*) init_mul_tables::sqr1_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- _deref_pbuz1=vbuz2 ldy #0 lda _5 - sta (sqr_lo),y - //SEG77 [36] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) -- vbuz1=_hi_vwuz2 + sta (sqr1_lo),y + //SEG158 [76] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) -- vbuz1=_hi_vwuz2 lda sqr+1 sta _6 - //SEG78 [37] *((byte*) init_mul_tables::sqr_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- _deref_pbuz1=vbuz2 + //SEG159 [77] *((byte*) init_mul_tables::sqr1_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- _deref_pbuz1=vbuz2 ldy #0 lda _6 - sta (sqr_hi),y - //SEG79 [38] (byte*) init_mul_tables::sqr_hi#1 ← ++ (byte*) init_mul_tables::sqr_hi#2 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- pbuz1=_inc_pbuz1 - inc sqr_hi + sta (sqr1_hi),y + //SEG160 [78] (byte*) init_mul_tables::sqr1_hi#1 ← ++ (byte*) init_mul_tables::sqr1_hi#2 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- pbuz1=_inc_pbuz1 + inc sqr1_hi bne !+ - inc sqr_hi+1 + inc sqr1_hi+1 !: - //SEG80 [39] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) -- vwuz1=vwuz1_plus_vbuz2 + //SEG161 [79] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) -- vwuz1=vwuz1_plus_vbuz2 lda x_2 clc adc sqr @@ -1301,93 +2836,446 @@ init_mul_tables: { bcc !+ inc sqr+1 !: - //SEG81 [40] (byte*) init_mul_tables::sqr_lo#1 ← ++ (byte*) init_mul_tables::sqr_lo#2 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) -- pbuz1=_inc_pbuz1 - inc sqr_lo + //SEG162 [80] (byte*) init_mul_tables::sqr1_lo#1 ← ++ (byte*) init_mul_tables::sqr1_lo#2 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) -- pbuz1=_inc_pbuz1 + inc sqr1_lo bne !+ - inc sqr_lo+1 + inc sqr1_lo+1 !: - //SEG82 [41] if((byte*) init_mul_tables::sqr_lo#1!=(const byte[512]) mul_sqr_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) -- pbuz1_neq_pbuc1_then_la1 - lda sqr_lo+1 - cmp #>mul_sqr_lo+$200 + //SEG163 [81] if((byte*) init_mul_tables::sqr1_lo#1!=(const byte[512]) mul_sqr1_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) -- pbuz1_neq_pbuc1_then_la1 + lda sqr1_lo+1 + cmp #>mul_sqr1_lo+$200 bne b1_from_b2 - lda sqr_lo - cmp #init_mul_tables::@3] + b3_from_b2: + //SEG165 [82] phi (byte) init_mul_tables::dir#2 = (byte/word/signed word) 255 [phi:init_mul_tables::@2->init_mul_tables::@3#0] -- vbuz1=vbuc1 + lda #$ff + sta dir + //SEG166 [82] phi (byte*) init_mul_tables::sqr2_hi#2 = (const byte[512]) mul_sqr2_hi#0 [phi:init_mul_tables::@2->init_mul_tables::@3#1] -- pbuz1=pbuc1 + lda #mul_sqr2_hi + sta sqr2_hi+1 + //SEG167 [82] phi (byte*) init_mul_tables::sqr2_lo#2 = (const byte[512]) mul_sqr2_lo#0 [phi:init_mul_tables::@2->init_mul_tables::@3#2] -- pbuz1=pbuc1 + lda #mul_sqr2_lo + sta sqr2_lo+1 + //SEG168 [82] phi (byte) init_mul_tables::x_255#2 = ((byte))-(byte/signed byte/word/signed word) 1 [phi:init_mul_tables::@2->init_mul_tables::@3#3] -- vbuz1=vbuc1 + lda #-1 + sta x_255 + jmp b3 + //SEG169 [82] phi from init_mul_tables::@4 to init_mul_tables::@3 [phi:init_mul_tables::@4->init_mul_tables::@3] + b3_from_b4: + //SEG170 [82] phi (byte) init_mul_tables::dir#2 = (byte) init_mul_tables::dir#3 [phi:init_mul_tables::@4->init_mul_tables::@3#0] -- register_copy + //SEG171 [82] phi (byte*) init_mul_tables::sqr2_hi#2 = (byte*) init_mul_tables::sqr2_hi#1 [phi:init_mul_tables::@4->init_mul_tables::@3#1] -- register_copy + //SEG172 [82] phi (byte*) init_mul_tables::sqr2_lo#2 = (byte*) init_mul_tables::sqr2_lo#1 [phi:init_mul_tables::@4->init_mul_tables::@3#2] -- register_copy + //SEG173 [82] phi (byte) init_mul_tables::x_255#2 = (byte) init_mul_tables::x_255#1 [phi:init_mul_tables::@4->init_mul_tables::@3#3] -- register_copy + jmp b3 + //SEG174 init_mul_tables::@3 + b3: + //SEG175 [83] *((byte*) init_mul_tables::sqr2_lo#2) ← *((const byte[512]) mul_sqr1_lo#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) -- _deref_pbuz1=pbuc1_derefidx_vbuz2 + ldx x_255 + lda mul_sqr1_lo,x + ldy #0 + sta (sqr2_lo),y + //SEG176 [84] *((byte*) init_mul_tables::sqr2_hi#2) ← *((const byte[512]) mul_sqr1_hi#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) -- _deref_pbuz1=pbuc1_derefidx_vbuz2 + ldx x_255 + lda mul_sqr1_hi,x + ldy #0 + sta (sqr2_hi),y + //SEG177 [85] (byte*) init_mul_tables::sqr2_hi#1 ← ++ (byte*) init_mul_tables::sqr2_hi#2 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::sqr2_hi#1 ] ) -- pbuz1=_inc_pbuz1 + inc sqr2_hi + bne !+ + inc sqr2_hi+1 + !: + //SEG178 [86] (byte) init_mul_tables::x_255#1 ← (byte) init_mul_tables::x_255#2 + (byte) init_mul_tables::dir#2 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) -- vbuz1=vbuz1_plus_vbuz2 + lda x_255 + clc + adc dir + sta x_255 + //SEG179 [87] if((byte) init_mul_tables::x_255#1!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@12 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) -- vbuz1_neq_0_then_la1 + lda x_255 + bne b12_from_b3 + //SEG180 [88] phi from init_mul_tables::@3 to init_mul_tables::@4 [phi:init_mul_tables::@3->init_mul_tables::@4] + b4_from_b3: + //SEG181 [88] phi (byte) init_mul_tables::dir#3 = (byte/signed byte/word/signed word) 1 [phi:init_mul_tables::@3->init_mul_tables::@4#0] -- vbuz1=vbuc1 + lda #1 + sta dir + jmp b4 + //SEG182 init_mul_tables::@4 + b4: + //SEG183 [89] (byte*) init_mul_tables::sqr2_lo#1 ← ++ (byte*) init_mul_tables::sqr2_lo#2 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) -- pbuz1=_inc_pbuz1 + inc sqr2_lo + bne !+ + inc sqr2_lo+1 + !: + //SEG184 [90] if((byte*) init_mul_tables::sqr2_lo#1!=(const byte[512]) mul_sqr2_lo#0+(word/signed word) 511) goto init_mul_tables::@3 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) -- pbuz1_neq_pbuc1_then_la1 + lda sqr2_lo+1 + cmp #>mul_sqr2_lo+$1ff + bne b3_from_b4 + lda sqr2_lo + cmp #init_mul_tables::@12] + b12_from_b3: + jmp b12 + //SEG191 init_mul_tables::@12 + b12: + //SEG192 [88] phi from init_mul_tables::@12 to init_mul_tables::@4 [phi:init_mul_tables::@12->init_mul_tables::@4] + b4_from_b12: + //SEG193 [88] phi (byte) init_mul_tables::dir#3 = (byte) init_mul_tables::dir#2 [phi:init_mul_tables::@12->init_mul_tables::@4#0] -- register_copy + jmp b4 } REGISTER UPLIFT POTENTIAL REGISTERS Statement [11] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 5 [ ] ( main:2::mul_tables_compare:9 [ ] ) always clobbers reg byte a -Statement [13] if(*((const byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Removing always clobbered register reg byte a as potential for zp ZP_BYTE:2 [ mul_tables_compare::i#10 mul_tables_compare::i#1 ] -Statement [14] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement [15] if(*((const byte[512]) mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@3 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement [16] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement [17] if(*((const byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@4 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement [18] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement [19] if(*((const byte[512]) mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@5 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement [20] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr_lo,xbnelb1incml0+2incml1+2clcinybnelb1 } always clobbers reg byte a reg byte x reg byte y -Statement [29] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) always clobbers reg byte a -Removing always clobbered register reg byte a as potential for zp ZP_BYTE:8 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] -Removing always clobbered register reg byte a as potential for zp ZP_BYTE:3 [ init_mul_tables::c#2 init_mul_tables::c#1 ] -Statement [34] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) always clobbers reg byte a -Statement [35] *((byte*) init_mul_tables::sqr_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) always clobbers reg byte y -Removing always clobbered register reg byte y as potential for zp ZP_BYTE:3 [ init_mul_tables::c#2 init_mul_tables::c#1 ] -Removing always clobbered register reg byte y as potential for zp ZP_BYTE:8 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] -Statement [36] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) always clobbers reg byte a -Statement [37] *((byte*) init_mul_tables::sqr_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) always clobbers reg byte y -Statement [39] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) always clobbers reg byte a -Statement [41] if((byte*) init_mul_tables::sqr_lo#1!=(const byte[512]) mul_sqr_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) always clobbers reg byte a +Statement [13] if(*((byte*) mul_tables_compare::kc_sqr#2)==*((byte*) mul_tables_compare::asm_sqr#2)) goto mul_tables_compare::@2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) always clobbers reg byte a reg byte y +Statement [14] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) always clobbers reg byte a +Statement [18] (word) print_word::w#0 ← ((word)) (byte*) mul_tables_compare::asm_sqr#2 [ mul_tables_compare::kc_sqr#2 print_word::w#0 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 print_word::w#0 char_cursor#19 ] ) always clobbers reg byte a +Statement [22] (word) print_word::w#1 ← ((word)) (byte*) mul_tables_compare::kc_sqr#2 [ print_word::w#1 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ print_word::w#1 char_cursor#19 ] ) always clobbers reg byte a +Statement [28] if((byte*) mul_tables_compare::kc_sqr#1<(const byte[512]) mul_sqr1_lo#0+(word/signed word) 512*(byte/signed byte/word/signed word) 4) goto mul_tables_compare::@1 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ) always clobbers reg byte a +Succesfully loaded fragment vbuaa=_hi_vwuz1 +Attempting fragment synthesis vbuxx=_hi_vwuz1 +Succesfully loaded fragment vbuaa=_hi_vwuz1 +Succesfully synthesized fragment vbuxx=_hi_vwuz1 (from vbuaa=_hi_vwuz1) +Attempting fragment synthesis vbuyy=_hi_vwuz1 +Succesfully loaded fragment vbuaa=_hi_vwuz1 +Succesfully synthesized fragment vbuyy=_hi_vwuz1 (from vbuaa=_hi_vwuz1) +Statement [30] (byte) print_byte::b#0 ← > (word) print_word::w#2 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#0 char_cursor#19 ] main:2::mul_tables_compare:9::print_word:23 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ) always clobbers reg byte a +Succesfully loaded fragment vbuaa=_lo_vwuz1 +Attempting fragment synthesis vbuxx=_lo_vwuz1 +Succesfully loaded fragment vbuaa=_lo_vwuz1 +Succesfully synthesized fragment vbuxx=_lo_vwuz1 (from vbuaa=_lo_vwuz1) +Attempting fragment synthesis vbuyy=_lo_vwuz1 +Succesfully loaded fragment vbuaa=_lo_vwuz1 +Succesfully synthesized fragment vbuyy=_lo_vwuz1 (from vbuaa=_lo_vwuz1) +Statement [32] (byte) print_byte::b#1 ← < (word) print_word::w#2 [ char_cursor#10 print_byte::b#1 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::b#1 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 print_byte::b#1 ] ) always clobbers reg byte a +Attempting fragment synthesis vbuz1=vbuaa_ror_4 +Succesfully loaded fragment vbuaa=vbuaa_ror_4 +Succesfully synthesized fragment vbuz1=vbuaa_ror_4 (from vbuaa=vbuaa_ror_4) +Attempting fragment synthesis vbuaa=pbuc1_derefidx_vbuz1 +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuz1 +Succesfully synthesized fragment vbuaa=pbuc1_derefidx_vbuz1 (from vbuaa=vwuc1_derefidx_vbuz1) +Attempting fragment synthesis vbuxx=pbuc1_derefidx_vbuz1 +Succesfully loaded fragment vbuxx=vwuc1_derefidx_vbuz1 +Succesfully synthesized fragment vbuxx=pbuc1_derefidx_vbuz1 (from vbuxx=vwuc1_derefidx_vbuz1) +Attempting fragment synthesis vbuyy=pbuc1_derefidx_vbuz1 +Attempting fragment synthesis vbuyy=vwuc1_derefidx_vbuz1 +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuz1 +Succesfully synthesized fragment vbuyy=vwuc1_derefidx_vbuz1 (from vbuaa=vwuc1_derefidx_vbuz1) +Succesfully synthesized fragment vbuyy=pbuc1_derefidx_vbuz1 (from vbuyy=vwuc1_derefidx_vbuz1) +Attempting fragment synthesis vbuz1=pbuc1_derefidx_vbuaa +Attempting fragment synthesis vbuz1=vwuc1_derefidx_vbuaa +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuaa +Succesfully synthesized fragment vbuz1=vwuc1_derefidx_vbuaa (from vbuaa=vwuc1_derefidx_vbuaa) +Succesfully synthesized fragment vbuz1=pbuc1_derefidx_vbuaa (from vbuz1=vwuc1_derefidx_vbuaa) +Attempting fragment synthesis vbuaa=pbuc1_derefidx_vbuaa +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuaa +Succesfully synthesized fragment vbuaa=pbuc1_derefidx_vbuaa (from vbuaa=vwuc1_derefidx_vbuaa) +Attempting fragment synthesis vbuxx=pbuc1_derefidx_vbuaa +Succesfully loaded fragment vbuxx=vwuc1_derefidx_vbuaa +Succesfully synthesized fragment vbuxx=pbuc1_derefidx_vbuaa (from vbuxx=vwuc1_derefidx_vbuaa) +Attempting fragment synthesis vbuyy=pbuc1_derefidx_vbuaa +Attempting fragment synthesis vbuyy=vwuc1_derefidx_vbuaa +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuaa +Succesfully synthesized fragment vbuyy=vwuc1_derefidx_vbuaa (from vbuaa=vwuc1_derefidx_vbuaa) +Succesfully synthesized fragment vbuyy=pbuc1_derefidx_vbuaa (from vbuyy=vwuc1_derefidx_vbuaa) +Attempting fragment synthesis vbuz1=pbuc1_derefidx_vbuxx +Attempting fragment synthesis vbuz1=vwuc1_derefidx_vbuxx +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuxx +Succesfully synthesized fragment vbuz1=vwuc1_derefidx_vbuxx (from vbuaa=vwuc1_derefidx_vbuxx) +Succesfully synthesized fragment vbuz1=pbuc1_derefidx_vbuxx (from vbuz1=vwuc1_derefidx_vbuxx) +Attempting fragment synthesis vbuaa=pbuc1_derefidx_vbuxx +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuxx +Succesfully synthesized fragment vbuaa=pbuc1_derefidx_vbuxx (from vbuaa=vwuc1_derefidx_vbuxx) +Attempting fragment synthesis vbuxx=pbuc1_derefidx_vbuxx +Succesfully loaded fragment vbuxx=vwuc1_derefidx_vbuxx +Succesfully synthesized fragment vbuxx=pbuc1_derefidx_vbuxx (from vbuxx=vwuc1_derefidx_vbuxx) +Attempting fragment synthesis vbuyy=pbuc1_derefidx_vbuxx +Succesfully loaded fragment vbuyy=vwuc1_derefidx_vbuxx +Succesfully synthesized fragment vbuyy=pbuc1_derefidx_vbuxx (from vbuyy=vwuc1_derefidx_vbuxx) +Attempting fragment synthesis vbuz1=vbuaa_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuz1=vbuaa_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Attempting fragment synthesis vbuz1=vbuxx_band_vbuc1 +Attempting fragment synthesis vbuaa=vbuxx_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuaa=vbuxx_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Succesfully synthesized fragment vbuz1=vbuxx_band_vbuc1 (from vbuaa=vbuxx_band_vbuc1) +Attempting fragment synthesis vbuz1=vbuyy_band_vbuc1 +Attempting fragment synthesis vbuaa=vbuyy_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuaa=vbuyy_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Succesfully synthesized fragment vbuz1=vbuyy_band_vbuc1 (from vbuaa=vbuyy_band_vbuc1) +Attempting fragment synthesis vbuaa=vbuz1_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuaa=vbuz1_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Attempting fragment synthesis vbuaa=vbuxx_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuaa=vbuxx_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Attempting fragment synthesis vbuaa=vbuyy_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuaa=vbuyy_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Attempting fragment synthesis vbuxx=vbuz1_band_vbuc1 +Attempting fragment synthesis vbuaa=vbuz1_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuaa=vbuz1_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Succesfully synthesized fragment vbuxx=vbuz1_band_vbuc1 (from vbuaa=vbuz1_band_vbuc1) +Attempting fragment synthesis vbuxx=vbuaa_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuxx=vbuaa_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Attempting fragment synthesis vbuxx=vbuxx_band_vbuc1 +Attempting fragment synthesis vbuaa=vbuxx_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuaa=vbuxx_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Succesfully synthesized fragment vbuxx=vbuxx_band_vbuc1 (from vbuaa=vbuxx_band_vbuc1) +Attempting fragment synthesis vbuxx=vbuyy_band_vbuc1 +Attempting fragment synthesis vbuaa=vbuyy_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuaa=vbuyy_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Succesfully synthesized fragment vbuxx=vbuyy_band_vbuc1 (from vbuaa=vbuyy_band_vbuc1) +Attempting fragment synthesis vbuyy=vbuz1_band_vbuc1 +Attempting fragment synthesis vbuaa=vbuz1_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuaa=vbuz1_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Succesfully synthesized fragment vbuyy=vbuz1_band_vbuc1 (from vbuaa=vbuz1_band_vbuc1) +Attempting fragment synthesis vbuyy=vbuaa_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuyy=vbuaa_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Attempting fragment synthesis vbuyy=vbuxx_band_vbuc1 +Attempting fragment synthesis vbuaa=vbuxx_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuaa=vbuxx_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Succesfully synthesized fragment vbuyy=vbuxx_band_vbuc1 (from vbuaa=vbuxx_band_vbuc1) +Attempting fragment synthesis vbuyy=vbuyy_band_vbuc1 +Attempting fragment synthesis vbuaa=vbuyy_band_vbuc1 +Succesfully loaded fragment vbuaa=vbuaa_band_vbuc1 +Succesfully synthesized fragment vbuaa=vbuyy_band_vbuc1 (from vbuaa=vbuaa_band_vbuc1) +Succesfully synthesized fragment vbuyy=vbuyy_band_vbuc1 (from vbuaa=vbuyy_band_vbuc1) +Statement [39] (byte~) print_byte::$2 ← (byte) print_byte::b#2 & (byte/signed byte/word/signed word) 15 [ char_cursor#10 print_byte::$2 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_byte::$2 ] ) always clobbers reg byte a +Succesfully loaded fragment _deref_pbuz1=vbuaa +Succesfully loaded fragment _deref_pbuz1=vbuxx +Succesfully loaded fragment _deref_pbuz1=vbuyy +Statement [44] *((byte*) char_cursor#27) ← (byte) print_char::ch#2 [ char_cursor#27 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#27 ] ) always clobbers reg byte y +Removing always clobbered register reg byte y as potential for zp ZP_BYTE:8 [ print_byte::b#2 print_byte::b#0 print_byte::b#1 ] +Statement [49] if(*((byte*) print_str::str#3)!=(byte) '@') goto print_str::@2 [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) always clobbers reg byte a reg byte y +Statement [51] *((byte*) char_cursor#19) ← *((byte*) print_str::str#3) [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) always clobbers reg byte a reg byte y +Statement [56] *((byte*) print_cls::sc#2) ← (byte) ' ' [ print_cls::sc#2 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#2 ] ) always clobbers reg byte a reg byte y +Statement [58] if((byte*) print_cls::sc#1!=(word/signed word) 1024+(word/signed word) 1000) goto print_cls::@1 [ print_cls::sc#1 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#1 ] ) always clobbers reg byte a +Statement asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr1_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr1_lo,xbnelb1incml0+2incml1+2clcinybnelb1ldx#$00ldy#$ff!:ldaasm_mul_sqr1_hi+1,xstaasm_mul_sqr2_hi+$100,xldaasm_mul_sqr1_hi,xstaasm_mul_sqr2_hi,yldaasm_mul_sqr1_lo+1,xstaasm_mul_sqr2_lo+$100,xldaasm_mul_sqr1_lo,xstaasm_mul_sqr2_lo,ydeyinxbne!- } always clobbers reg byte a reg byte x reg byte y +Statement [61] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) always clobbers reg byte a +Statement [62] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) always clobbers reg byte a +Statement [63] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) always clobbers reg byte a +Statement [64] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) always clobbers reg byte a +Statement [69] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) always clobbers reg byte a +Removing always clobbered register reg byte a as potential for zp ZP_BYTE:21 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] +Removing always clobbered register reg byte a as potential for zp ZP_BYTE:16 [ init_mul_tables::c#2 init_mul_tables::c#1 ] +Succesfully loaded fragment vbuaa_neq_0_then_la1 +Statement [74] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) always clobbers reg byte a +Statement [75] *((byte*) init_mul_tables::sqr1_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) always clobbers reg byte y +Removing always clobbered register reg byte y as potential for zp ZP_BYTE:16 [ init_mul_tables::c#2 init_mul_tables::c#1 ] +Removing always clobbered register reg byte y as potential for zp ZP_BYTE:21 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] +Statement [76] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) always clobbers reg byte a +Statement [77] *((byte*) init_mul_tables::sqr1_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) always clobbers reg byte y +Attempting fragment synthesis vwuz1=vwuz1_plus_vbuxx +Attempting fragment synthesis vwuz1=vbuxx_plus_vwuz1 +Succesfully loaded fragment vwuz1=vbuaa_plus_vwuz1 +Succesfully synthesized fragment vwuz1=vbuxx_plus_vwuz1 (from vwuz1=vbuaa_plus_vwuz1) +Succesfully synthesized fragment vwuz1=vwuz1_plus_vbuxx (from vwuz1=vbuxx_plus_vwuz1) +Statement [79] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) always clobbers reg byte a +Statement [81] if((byte*) init_mul_tables::sqr1_lo#1!=(const byte[512]) mul_sqr1_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) always clobbers reg byte a +Attempting fragment synthesis _deref_pbuz1=pbuc1_derefidx_vbuaa +Attempting fragment synthesis _deref_pbuz1=vwuc1_derefidx_vbuaa +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuaa +Succesfully synthesized fragment _deref_pbuz1=vwuc1_derefidx_vbuaa (from vbuaa=vwuc1_derefidx_vbuaa) +Succesfully synthesized fragment _deref_pbuz1=pbuc1_derefidx_vbuaa (from _deref_pbuz1=vwuc1_derefidx_vbuaa) +Attempting fragment synthesis _deref_pbuz1=pbuc1_derefidx_vbuxx +Attempting fragment synthesis _deref_pbuz1=vwuc1_derefidx_vbuxx +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuxx +Succesfully synthesized fragment _deref_pbuz1=vwuc1_derefidx_vbuxx (from vbuaa=vwuc1_derefidx_vbuxx) +Succesfully synthesized fragment _deref_pbuz1=pbuc1_derefidx_vbuxx (from _deref_pbuz1=vwuc1_derefidx_vbuxx) +Attempting fragment synthesis _deref_pbuz1=pbuc1_derefidx_vbuyy +Attempting fragment synthesis _deref_pbuz1=vwuc1_derefidx_vbuyy +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuyy +Succesfully synthesized fragment _deref_pbuz1=vwuc1_derefidx_vbuyy (from vbuaa=vwuc1_derefidx_vbuyy) +Succesfully synthesized fragment _deref_pbuz1=pbuc1_derefidx_vbuyy (from _deref_pbuz1=vwuc1_derefidx_vbuyy) +Statement [83] *((byte*) init_mul_tables::sqr2_lo#2) ← *((const byte[512]) mul_sqr1_lo#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) always clobbers reg byte a reg byte y +Removing always clobbered register reg byte a as potential for zp ZP_BYTE:24 [ init_mul_tables::x_255#2 init_mul_tables::x_255#1 ] +Removing always clobbered register reg byte y as potential for zp ZP_BYTE:24 [ init_mul_tables::x_255#2 init_mul_tables::x_255#1 ] +Removing always clobbered register reg byte a as potential for zp ZP_BYTE:29 [ init_mul_tables::dir#2 init_mul_tables::dir#3 ] +Removing always clobbered register reg byte y as potential for zp ZP_BYTE:29 [ init_mul_tables::dir#2 init_mul_tables::dir#3 ] +Statement [84] *((byte*) init_mul_tables::sqr2_hi#2) ← *((const byte[512]) mul_sqr1_hi#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) always clobbers reg byte a reg byte y +Attempting fragment synthesis vbuxx=vbuxx_plus_vbuz1 +Succesfully loaded fragment vbuaa=vbuxx_plus_vbuz1 +Succesfully synthesized fragment vbuxx=vbuxx_plus_vbuz1 (from vbuaa=vbuxx_plus_vbuz1) +Succesfully loaded fragment vbuz1=vbuz1_plus_vbuxx +Attempting fragment synthesis vbuxx=vbuxx_plus_vbuxx +Succesfully loaded fragment vbuaa=vbuxx_plus_vbuxx +Succesfully synthesized fragment vbuxx=vbuxx_plus_vbuxx (from vbuaa=vbuxx_plus_vbuxx) +Statement [86] (byte) init_mul_tables::x_255#1 ← (byte) init_mul_tables::x_255#2 + (byte) init_mul_tables::dir#2 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) always clobbers reg byte a +Succesfully loaded fragment vbuxx_neq_0_then_la1 +Statement [90] if((byte*) init_mul_tables::sqr2_lo#1!=(const byte[512]) mul_sqr2_lo#0+(word/signed word) 511) goto init_mul_tables::@3 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) always clobbers reg byte a +Statement [91] *((const byte[512]) mul_sqr2_lo#0+(word/signed word) 511) ← *((const byte[512]) mul_sqr1_lo#0+(word/signed word) 256) [ ] ( main:2::init_mul_tables:5 [ ] ) always clobbers reg byte a +Statement [92] *((const byte[512]) mul_sqr2_hi#0+(word/signed word) 511) ← *((const byte[512]) mul_sqr1_hi#0+(word/signed word) 256) [ ] ( main:2::init_mul_tables:5 [ ] ) always clobbers reg byte a Statement [11] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 5 [ ] ( main:2::mul_tables_compare:9 [ ] ) always clobbers reg byte a -Statement [13] if(*((const byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement [14] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement [15] if(*((const byte[512]) mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@3 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement [16] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement [17] if(*((const byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@4 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement [18] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement [19] if(*((const byte[512]) mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@5 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement [20] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) always clobbers reg byte a -Statement asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr_lo,xbnelb1incml0+2incml1+2clcinybnelb1 } always clobbers reg byte a reg byte x reg byte y -Statement [29] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) always clobbers reg byte a -Statement [34] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) always clobbers reg byte a -Statement [35] *((byte*) init_mul_tables::sqr_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) always clobbers reg byte y -Statement [36] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) always clobbers reg byte a -Statement [37] *((byte*) init_mul_tables::sqr_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) always clobbers reg byte y -Statement [39] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) always clobbers reg byte a -Statement [41] if((byte*) init_mul_tables::sqr_lo#1!=(const byte[512]) mul_sqr_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) always clobbers reg byte a -Potential registers zp ZP_BYTE:2 [ mul_tables_compare::i#10 mul_tables_compare::i#1 ] : zp ZP_BYTE:2 , reg byte x , reg byte y , -Potential registers zp ZP_BYTE:3 [ init_mul_tables::c#2 init_mul_tables::c#1 ] : zp ZP_BYTE:3 , reg byte x , -Potential registers zp ZP_WORD:4 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_lo#1 ] : zp ZP_WORD:4 , -Potential registers zp ZP_WORD:6 [ init_mul_tables::sqr_hi#2 init_mul_tables::sqr_hi#1 ] : zp ZP_WORD:6 , -Potential registers zp ZP_BYTE:8 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] : zp ZP_BYTE:8 , reg byte x , -Potential registers zp ZP_WORD:9 [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] : zp ZP_WORD:9 , -Potential registers zp ZP_BYTE:11 [ init_mul_tables::$2 ] : zp ZP_BYTE:11 , reg byte a , reg byte x , reg byte y , -Potential registers zp ZP_BYTE:12 [ init_mul_tables::$5 ] : zp ZP_BYTE:12 , reg byte a , reg byte x , reg byte y , -Potential registers zp ZP_BYTE:13 [ init_mul_tables::$6 ] : zp ZP_BYTE:13 , reg byte a , reg byte x , reg byte y , +Statement [13] if(*((byte*) mul_tables_compare::kc_sqr#2)==*((byte*) mul_tables_compare::asm_sqr#2)) goto mul_tables_compare::@2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) always clobbers reg byte a reg byte y +Statement [14] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) always clobbers reg byte a +Statement [18] (word) print_word::w#0 ← ((word)) (byte*) mul_tables_compare::asm_sqr#2 [ mul_tables_compare::kc_sqr#2 print_word::w#0 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 print_word::w#0 char_cursor#19 ] ) always clobbers reg byte a +Statement [22] (word) print_word::w#1 ← ((word)) (byte*) mul_tables_compare::kc_sqr#2 [ print_word::w#1 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ print_word::w#1 char_cursor#19 ] ) always clobbers reg byte a +Statement [28] if((byte*) mul_tables_compare::kc_sqr#1<(const byte[512]) mul_sqr1_lo#0+(word/signed word) 512*(byte/signed byte/word/signed word) 4) goto mul_tables_compare::@1 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ) always clobbers reg byte a +Statement [30] (byte) print_byte::b#0 ← > (word) print_word::w#2 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#0 char_cursor#19 ] main:2::mul_tables_compare:9::print_word:23 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ) always clobbers reg byte a +Statement [32] (byte) print_byte::b#1 ← < (word) print_word::w#2 [ char_cursor#10 print_byte::b#1 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::b#1 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 print_byte::b#1 ] ) always clobbers reg byte a +Statement [39] (byte~) print_byte::$2 ← (byte) print_byte::b#2 & (byte/signed byte/word/signed word) 15 [ char_cursor#10 print_byte::$2 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_byte::$2 ] ) always clobbers reg byte a +Statement [44] *((byte*) char_cursor#27) ← (byte) print_char::ch#2 [ char_cursor#27 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#27 ] ) always clobbers reg byte y +Statement [49] if(*((byte*) print_str::str#3)!=(byte) '@') goto print_str::@2 [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) always clobbers reg byte a reg byte y +Statement [51] *((byte*) char_cursor#19) ← *((byte*) print_str::str#3) [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) always clobbers reg byte a reg byte y +Statement [56] *((byte*) print_cls::sc#2) ← (byte) ' ' [ print_cls::sc#2 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#2 ] ) always clobbers reg byte a reg byte y +Statement [58] if((byte*) print_cls::sc#1!=(word/signed word) 1024+(word/signed word) 1000) goto print_cls::@1 [ print_cls::sc#1 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#1 ] ) always clobbers reg byte a +Statement asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr1_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr1_lo,xbnelb1incml0+2incml1+2clcinybnelb1ldx#$00ldy#$ff!:ldaasm_mul_sqr1_hi+1,xstaasm_mul_sqr2_hi+$100,xldaasm_mul_sqr1_hi,xstaasm_mul_sqr2_hi,yldaasm_mul_sqr1_lo+1,xstaasm_mul_sqr2_lo+$100,xldaasm_mul_sqr1_lo,xstaasm_mul_sqr2_lo,ydeyinxbne!- } always clobbers reg byte a reg byte x reg byte y +Statement [61] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) always clobbers reg byte a +Statement [62] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) always clobbers reg byte a +Statement [63] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) always clobbers reg byte a +Statement [64] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) always clobbers reg byte a +Statement [69] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) always clobbers reg byte a +Statement [74] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) always clobbers reg byte a +Statement [75] *((byte*) init_mul_tables::sqr1_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) always clobbers reg byte y +Statement [76] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) always clobbers reg byte a +Statement [77] *((byte*) init_mul_tables::sqr1_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) always clobbers reg byte y +Statement [79] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) always clobbers reg byte a +Statement [81] if((byte*) init_mul_tables::sqr1_lo#1!=(const byte[512]) mul_sqr1_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) always clobbers reg byte a +Statement [83] *((byte*) init_mul_tables::sqr2_lo#2) ← *((const byte[512]) mul_sqr1_lo#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) always clobbers reg byte a reg byte y +Statement [84] *((byte*) init_mul_tables::sqr2_hi#2) ← *((const byte[512]) mul_sqr1_hi#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) always clobbers reg byte a reg byte y +Statement [86] (byte) init_mul_tables::x_255#1 ← (byte) init_mul_tables::x_255#2 + (byte) init_mul_tables::dir#2 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) always clobbers reg byte a +Statement [90] if((byte*) init_mul_tables::sqr2_lo#1!=(const byte[512]) mul_sqr2_lo#0+(word/signed word) 511) goto init_mul_tables::@3 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) always clobbers reg byte a +Statement [91] *((const byte[512]) mul_sqr2_lo#0+(word/signed word) 511) ← *((const byte[512]) mul_sqr1_lo#0+(word/signed word) 256) [ ] ( main:2::init_mul_tables:5 [ ] ) always clobbers reg byte a +Statement [92] *((const byte[512]) mul_sqr2_hi#0+(word/signed word) 511) ← *((const byte[512]) mul_sqr1_hi#0+(word/signed word) 256) [ ] ( main:2::init_mul_tables:5 [ ] ) always clobbers reg byte a +Potential registers zp ZP_WORD:2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::kc_sqr#1 ] : zp ZP_WORD:2 , +Potential registers zp ZP_WORD:4 [ mul_tables_compare::asm_sqr#2 mul_tables_compare::asm_sqr#1 ] : zp ZP_WORD:4 , +Potential registers zp ZP_WORD:6 [ print_word::w#2 print_word::w#0 print_word::w#1 ] : zp ZP_WORD:6 , +Potential registers zp ZP_BYTE:8 [ print_byte::b#2 print_byte::b#0 print_byte::b#1 ] : zp ZP_BYTE:8 , reg byte a , reg byte x , +Potential registers zp ZP_BYTE:9 [ print_char::ch#2 print_char::ch#0 print_char::ch#1 ] : zp ZP_BYTE:9 , reg byte a , reg byte x , reg byte y , +Potential registers zp ZP_WORD:10 [ char_cursor#44 char_cursor#27 char_cursor#39 char_cursor#19 char_cursor#17 char_cursor#10 char_cursor#1 ] : zp ZP_WORD:10 , +Potential registers zp ZP_WORD:12 [ print_str::str#3 print_str::str#5 print_str::str#0 ] : zp ZP_WORD:12 , +Potential registers zp ZP_WORD:14 [ print_cls::sc#2 print_cls::sc#1 ] : zp ZP_WORD:14 , +Potential registers zp ZP_BYTE:16 [ init_mul_tables::c#2 init_mul_tables::c#1 ] : zp ZP_BYTE:16 , reg byte x , +Potential registers zp ZP_WORD:17 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_lo#1 ] : zp ZP_WORD:17 , +Potential registers zp ZP_WORD:19 [ init_mul_tables::sqr1_hi#2 init_mul_tables::sqr1_hi#1 ] : zp ZP_WORD:19 , +Potential registers zp ZP_BYTE:21 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] : zp ZP_BYTE:21 , reg byte x , +Potential registers zp ZP_WORD:22 [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] : zp ZP_WORD:22 , +Potential registers zp ZP_BYTE:24 [ init_mul_tables::x_255#2 init_mul_tables::x_255#1 ] : zp ZP_BYTE:24 , reg byte x , +Potential registers zp ZP_WORD:25 [ init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_lo#1 ] : zp ZP_WORD:25 , +Potential registers zp ZP_WORD:27 [ init_mul_tables::sqr2_hi#2 init_mul_tables::sqr2_hi#1 ] : zp ZP_WORD:27 , +Potential registers zp ZP_BYTE:29 [ init_mul_tables::dir#2 init_mul_tables::dir#3 ] : zp ZP_BYTE:29 , reg byte x , +Potential registers zp ZP_BYTE:30 [ print_byte::$0 ] : zp ZP_BYTE:30 , reg byte a , reg byte x , reg byte y , +Potential registers zp ZP_BYTE:31 [ print_byte::$2 ] : zp ZP_BYTE:31 , reg byte a , reg byte x , reg byte y , +Potential registers zp ZP_BYTE:32 [ init_mul_tables::$2 ] : zp ZP_BYTE:32 , reg byte a , reg byte x , reg byte y , +Potential registers zp ZP_BYTE:33 [ init_mul_tables::$5 ] : zp ZP_BYTE:33 , reg byte a , reg byte x , reg byte y , +Potential registers zp ZP_BYTE:34 [ init_mul_tables::$6 ] : zp ZP_BYTE:34 , reg byte a , reg byte x , reg byte y , REGISTER UPLIFT SCOPES -Uplift Scope [init_mul_tables] 45.1: zp ZP_WORD:9 [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] 24.36: zp ZP_BYTE:3 [ init_mul_tables::c#2 init_mul_tables::c#1 ] 24.14: zp ZP_BYTE:8 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] 22: zp ZP_BYTE:11 [ init_mul_tables::$2 ] 22: zp ZP_BYTE:12 [ init_mul_tables::$5 ] 22: zp ZP_BYTE:13 [ init_mul_tables::$6 ] 19.04: zp ZP_WORD:4 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_lo#1 ] 8.5: zp ZP_WORD:6 [ init_mul_tables::sqr_hi#2 init_mul_tables::sqr_hi#1 ] -Uplift Scope [mul_tables_compare] 28.72: zp ZP_BYTE:2 [ mul_tables_compare::i#10 mul_tables_compare::i#1 ] +Uplift Scope [init_mul_tables] 45.1: zp ZP_WORD:22 [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] 24.36: zp ZP_BYTE:16 [ init_mul_tables::c#2 init_mul_tables::c#1 ] 24.14: zp ZP_BYTE:21 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] 22: zp ZP_BYTE:32 [ init_mul_tables::$2 ] 22: zp ZP_BYTE:33 [ init_mul_tables::$5 ] 22: zp ZP_BYTE:34 [ init_mul_tables::$6 ] 20.62: zp ZP_WORD:25 [ init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_lo#1 ] 19.04: zp ZP_WORD:17 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_lo#1 ] 16.5: zp ZP_BYTE:24 [ init_mul_tables::x_255#2 init_mul_tables::x_255#1 ] 14.14: zp ZP_WORD:27 [ init_mul_tables::sqr2_hi#2 init_mul_tables::sqr2_hi#1 ] 12.05: zp ZP_BYTE:29 [ init_mul_tables::dir#2 init_mul_tables::dir#3 ] 8.5: zp ZP_WORD:19 [ init_mul_tables::sqr1_hi#2 init_mul_tables::sqr1_hi#1 ] +Uplift Scope [] 45.41: zp ZP_WORD:10 [ char_cursor#44 char_cursor#27 char_cursor#39 char_cursor#19 char_cursor#17 char_cursor#10 char_cursor#1 ] +Uplift Scope [print_str] 35.5: zp ZP_WORD:12 [ print_str::str#3 print_str::str#5 print_str::str#0 ] +Uplift Scope [print_cls] 33: zp ZP_WORD:14 [ print_cls::sc#2 print_cls::sc#1 ] +Uplift Scope [mul_tables_compare] 19.68: zp ZP_WORD:2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::kc_sqr#1 ] 13.17: zp ZP_WORD:4 [ mul_tables_compare::asm_sqr#2 mul_tables_compare::asm_sqr#1 ] +Uplift Scope [print_byte] 10: zp ZP_BYTE:8 [ print_byte::b#2 print_byte::b#0 print_byte::b#1 ] 4: zp ZP_BYTE:30 [ print_byte::$0 ] 4: zp ZP_BYTE:31 [ print_byte::$2 ] +Uplift Scope [print_char] 14: zp ZP_BYTE:9 [ print_char::ch#2 print_char::ch#0 print_char::ch#1 ] +Uplift Scope [print_word] 10.67: zp ZP_WORD:6 [ print_word::w#2 print_word::w#0 print_word::w#1 ] Uplift Scope [main] Uplift Scope [init_mul_tables_asm] -Uplift Scope [] -Uplifting [init_mul_tables] best 3127 combination zp ZP_WORD:9 [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] reg byte x [ init_mul_tables::c#2 init_mul_tables::c#1 ] zp ZP_BYTE:8 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] reg byte a [ init_mul_tables::$2 ] reg byte a [ init_mul_tables::$5 ] reg byte a [ init_mul_tables::$6 ] zp ZP_WORD:4 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_lo#1 ] zp ZP_WORD:6 [ init_mul_tables::sqr_hi#2 init_mul_tables::sqr_hi#1 ] -Uplifting [mul_tables_compare] best 2937 combination reg byte x [ mul_tables_compare::i#10 mul_tables_compare::i#1 ] -Uplifting [main] best 2937 combination -Uplifting [init_mul_tables_asm] best 2937 combination -Uplifting [] best 2937 combination -Attempting to uplift remaining variables inzp ZP_BYTE:8 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] -Uplifting [init_mul_tables] best 2937 combination zp ZP_BYTE:8 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] -Allocated (was zp ZP_WORD:4) zp ZP_WORD:2 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_lo#1 ] -Allocated (was zp ZP_WORD:6) zp ZP_WORD:4 [ init_mul_tables::sqr_hi#2 init_mul_tables::sqr_hi#1 ] -Allocated (was zp ZP_BYTE:8) zp ZP_BYTE:6 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] -Allocated (was zp ZP_WORD:9) zp ZP_WORD:7 [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] +Succesfully loaded fragment vbuxx=vbuc1 +Succesfully loaded fragment vbuxx=_inc_vbuxx +Succesfully loaded fragment vbuyy_neq_0_then_la1 +Uplifting [init_mul_tables] best 5670 combination zp ZP_WORD:22 [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] reg byte x [ init_mul_tables::c#2 init_mul_tables::c#1 ] zp ZP_BYTE:21 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] reg byte a [ init_mul_tables::$2 ] reg byte a [ init_mul_tables::$5 ] reg byte a [ init_mul_tables::$6 ] zp ZP_WORD:25 [ init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_lo#1 ] zp ZP_WORD:17 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_lo#1 ] reg byte x [ init_mul_tables::x_255#2 init_mul_tables::x_255#1 ] zp ZP_WORD:27 [ init_mul_tables::sqr2_hi#2 init_mul_tables::sqr2_hi#1 ] zp ZP_BYTE:29 [ init_mul_tables::dir#2 init_mul_tables::dir#3 ] zp ZP_WORD:19 [ init_mul_tables::sqr1_hi#2 init_mul_tables::sqr1_hi#1 ] +Uplifting [] best 5670 combination zp ZP_WORD:10 [ char_cursor#44 char_cursor#27 char_cursor#39 char_cursor#19 char_cursor#17 char_cursor#10 char_cursor#1 ] +Uplifting [print_str] best 5670 combination zp ZP_WORD:12 [ print_str::str#3 print_str::str#5 print_str::str#0 ] +Uplifting [print_cls] best 5670 combination zp ZP_WORD:14 [ print_cls::sc#2 print_cls::sc#1 ] +Uplifting [mul_tables_compare] best 5670 combination zp ZP_WORD:2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::kc_sqr#1 ] zp ZP_WORD:4 [ mul_tables_compare::asm_sqr#2 mul_tables_compare::asm_sqr#1 ] +Attempting fragment synthesis vbuz1=vbuxx_ror_4 +Attempting fragment synthesis vbuaa=vbuxx_ror_4 +Succesfully loaded fragment vbuaa=vbuaa_ror_4 +Succesfully synthesized fragment vbuaa=vbuxx_ror_4 (from vbuaa=vbuaa_ror_4) +Succesfully synthesized fragment vbuz1=vbuxx_ror_4 (from vbuaa=vbuxx_ror_4) +Attempting fragment synthesis vbuaa=vbuz1_ror_4 +Succesfully loaded fragment vbuaa=vbuaa_ror_4 +Succesfully synthesized fragment vbuaa=vbuz1_ror_4 (from vbuaa=vbuaa_ror_4) +Attempting fragment synthesis vbuaa=vbuxx_ror_4 +Succesfully loaded fragment vbuaa=vbuaa_ror_4 +Succesfully synthesized fragment vbuaa=vbuxx_ror_4 (from vbuaa=vbuaa_ror_4) +Attempting fragment synthesis vbuxx=vbuz1_ror_4 +Attempting fragment synthesis vbuaa=vbuz1_ror_4 +Succesfully loaded fragment vbuaa=vbuaa_ror_4 +Succesfully synthesized fragment vbuaa=vbuz1_ror_4 (from vbuaa=vbuaa_ror_4) +Succesfully synthesized fragment vbuxx=vbuz1_ror_4 (from vbuaa=vbuz1_ror_4) +Attempting fragment synthesis vbuxx=vbuaa_ror_4 +Succesfully loaded fragment vbuaa=vbuaa_ror_4 +Succesfully synthesized fragment vbuxx=vbuaa_ror_4 (from vbuaa=vbuaa_ror_4) +Attempting fragment synthesis vbuyy=vbuz1_ror_4 +Attempting fragment synthesis vbuaa=vbuz1_ror_4 +Succesfully loaded fragment vbuaa=vbuaa_ror_4 +Succesfully synthesized fragment vbuaa=vbuz1_ror_4 (from vbuaa=vbuaa_ror_4) +Succesfully synthesized fragment vbuyy=vbuz1_ror_4 (from vbuaa=vbuz1_ror_4) +Attempting fragment synthesis vbuz1=pbuc1_derefidx_vbuyy +Attempting fragment synthesis vbuz1=vwuc1_derefidx_vbuyy +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuyy +Succesfully synthesized fragment vbuz1=vwuc1_derefidx_vbuyy (from vbuaa=vwuc1_derefidx_vbuyy) +Succesfully synthesized fragment vbuz1=pbuc1_derefidx_vbuyy (from vbuz1=vwuc1_derefidx_vbuyy) +Attempting fragment synthesis vbuyy=vbuaa_ror_4 +Succesfully loaded fragment vbuaa=vbuaa_ror_4 +Succesfully synthesized fragment vbuyy=vbuaa_ror_4 (from vbuaa=vbuaa_ror_4) +Attempting fragment synthesis vbuyy=vbuxx_ror_4 +Attempting fragment synthesis vbuaa=vbuxx_ror_4 +Succesfully loaded fragment vbuaa=vbuaa_ror_4 +Succesfully synthesized fragment vbuaa=vbuxx_ror_4 (from vbuaa=vbuaa_ror_4) +Succesfully synthesized fragment vbuyy=vbuxx_ror_4 (from vbuaa=vbuxx_ror_4) +Uplifting [print_byte] best 5658 combination reg byte x [ print_byte::b#2 print_byte::b#0 print_byte::b#1 ] reg byte y [ print_byte::$0 ] reg byte a [ print_byte::$2 ] +Attempting fragment synthesis vbuaa=pbuc1_derefidx_vbuyy +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuyy +Succesfully synthesized fragment vbuaa=pbuc1_derefidx_vbuyy (from vbuaa=vwuc1_derefidx_vbuyy) +Attempting fragment synthesis vbuyy=pbuc1_derefidx_vbuyy +Attempting fragment synthesis vbuyy=vwuc1_derefidx_vbuyy +Succesfully loaded fragment vbuaa=vwuc1_derefidx_vbuyy +Succesfully synthesized fragment vbuyy=vwuc1_derefidx_vbuyy (from vbuaa=vwuc1_derefidx_vbuyy) +Succesfully synthesized fragment vbuyy=pbuc1_derefidx_vbuyy (from vbuyy=vwuc1_derefidx_vbuyy) +Uplifting [print_char] best 5649 combination reg byte a [ print_char::ch#2 print_char::ch#0 print_char::ch#1 ] +Uplifting [print_word] best 5649 combination zp ZP_WORD:6 [ print_word::w#2 print_word::w#0 print_word::w#1 ] +Uplifting [main] best 5649 combination +Uplifting [init_mul_tables_asm] best 5649 combination +Attempting to uplift remaining variables inzp ZP_BYTE:21 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] +Uplifting [init_mul_tables] best 5649 combination zp ZP_BYTE:21 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] +Attempting to uplift remaining variables inzp ZP_BYTE:29 [ init_mul_tables::dir#2 init_mul_tables::dir#3 ] +Uplifting [init_mul_tables] best 5649 combination zp ZP_BYTE:29 [ init_mul_tables::dir#2 init_mul_tables::dir#3 ] +Coalescing zero page register [ zp ZP_WORD:2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::kc_sqr#1 ] ] with [ zp ZP_WORD:17 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_lo#1 ] ] +Coalescing zero page register [ zp ZP_WORD:2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::kc_sqr#1 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_lo#1 ] ] with [ zp ZP_WORD:25 [ init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_lo#1 ] ] +Coalescing zero page register [ zp ZP_WORD:4 [ mul_tables_compare::asm_sqr#2 mul_tables_compare::asm_sqr#1 ] ] with [ zp ZP_WORD:6 [ print_word::w#2 print_word::w#0 print_word::w#1 ] ] +Coalescing zero page register [ zp ZP_WORD:4 [ mul_tables_compare::asm_sqr#2 mul_tables_compare::asm_sqr#1 print_word::w#2 print_word::w#0 print_word::w#1 ] ] with [ zp ZP_WORD:19 [ init_mul_tables::sqr1_hi#2 init_mul_tables::sqr1_hi#1 ] ] +Coalescing zero page register [ zp ZP_WORD:4 [ mul_tables_compare::asm_sqr#2 mul_tables_compare::asm_sqr#1 print_word::w#2 print_word::w#0 print_word::w#1 init_mul_tables::sqr1_hi#2 init_mul_tables::sqr1_hi#1 ] ] with [ zp ZP_WORD:27 [ init_mul_tables::sqr2_hi#2 init_mul_tables::sqr2_hi#1 ] ] +Coalescing zero page register [ zp ZP_WORD:10 [ char_cursor#44 char_cursor#27 char_cursor#39 char_cursor#19 char_cursor#17 char_cursor#10 char_cursor#1 ] ] with [ zp ZP_WORD:14 [ print_cls::sc#2 print_cls::sc#1 ] ] +Coalescing zero page register [ zp ZP_WORD:10 [ char_cursor#44 char_cursor#27 char_cursor#39 char_cursor#19 char_cursor#17 char_cursor#10 char_cursor#1 print_cls::sc#2 print_cls::sc#1 ] ] with [ zp ZP_WORD:22 [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] ] +Coalescing zero page register [ zp ZP_BYTE:21 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] ] with [ zp ZP_BYTE:29 [ init_mul_tables::dir#2 init_mul_tables::dir#3 ] ] +Allocated (was zp ZP_WORD:10) zp ZP_WORD:6 [ char_cursor#44 char_cursor#27 char_cursor#39 char_cursor#19 char_cursor#17 char_cursor#10 char_cursor#1 print_cls::sc#2 print_cls::sc#1 init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] +Allocated (was zp ZP_WORD:12) zp ZP_WORD:8 [ print_str::str#3 print_str::str#5 print_str::str#0 ] +Allocated (was zp ZP_BYTE:21) zp ZP_BYTE:10 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 init_mul_tables::dir#2 init_mul_tables::dir#3 ] +Succesfully loaded fragment vwuz1=_word_pbuz1 ASSEMBLER BEFORE OPTIMIZATION //SEG0 Basic Upstart @@ -1396,30 +3284,35 @@ ASSEMBLER BEFORE OPTIMIZATION .pc = $80d "Program" //SEG1 Global Constants & labels .const BGCOL = $d021 - mul_sqr_lo: .fill 512, 0 - mul_sqr_hi: .fill 512, 0 - asm_mul_sqr_lo: .fill 512, 0 - asm_mul_sqr_hi: .fill 512, 0 + .label char_cursor = 6 + mul_sqr1_lo: .fill 512, 0 + mul_sqr1_hi: .fill 512, 0 + mul_sqr2_lo: .fill 512, 0 + mul_sqr2_hi: .fill 512, 0 + asm_mul_sqr1_lo: .fill 512, 0 + asm_mul_sqr1_hi: .fill 512, 0 + asm_mul_sqr2_lo: .fill 512, 0 + asm_mul_sqr2_hi: .fill 512, 0 //SEG2 @begin bbegin: -//SEG3 [1] phi from @begin to @4 [phi:@begin->@4] -b4_from_bbegin: - jmp b4 -//SEG4 @4 -b4: +//SEG3 [1] phi from @begin to @10 [phi:@begin->@10] +b10_from_bbegin: + jmp b10 +//SEG4 @10 +b10: //SEG5 [2] call main param-assignment [ ] ( ) -//SEG6 [4] phi from @4 to main [phi:@4->main] -main_from_b4: +//SEG6 [4] phi from @10 to main [phi:@10->main] +main_from_b10: jsr main -//SEG7 [3] phi from @4 to @end [phi:@4->@end] -bend_from_b4: +//SEG7 [3] phi from @10 to @end [phi:@10->@end] +bend_from_b10: jmp bend //SEG8 @end bend: //SEG9 main main: { //SEG10 [5] call init_mul_tables param-assignment [ ] ( main:2 [ ] ) - //SEG11 [26] phi from main to init_mul_tables [phi:main->init_mul_tables] + //SEG11 [66] phi from main to init_mul_tables [phi:main->init_mul_tables] init_mul_tables_from_main: jsr init_mul_tables //SEG12 [6] phi from main to main::@1 [phi:main->main::@1] @@ -1444,86 +3337,311 @@ main: { } //SEG20 mul_tables_compare mul_tables_compare: { + .label asm_sqr = 4 + .label kc_sqr = 2 //SEG21 [11] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 5 [ ] ( main:2::mul_tables_compare:9 [ ] ) -- _deref_pbuc1=vbuc2 lda #5 sta BGCOL //SEG22 [12] phi from mul_tables_compare to mul_tables_compare::@1 [phi:mul_tables_compare->mul_tables_compare::@1] b1_from_mul_tables_compare: - //SEG23 [12] phi (byte) mul_tables_compare::i#10 = (byte/signed byte/word/signed word) 0 [phi:mul_tables_compare->mul_tables_compare::@1#0] -- vbuxx=vbuc1 - ldx #0 + //SEG23 [12] phi (byte*) mul_tables_compare::asm_sqr#2 = (const byte[512]) asm_mul_sqr1_lo#0 [phi:mul_tables_compare->mul_tables_compare::@1#0] -- pbuz1=pbuc1 + lda #asm_mul_sqr1_lo + sta asm_sqr+1 + //SEG24 [12] phi (byte*) mul_tables_compare::kc_sqr#2 = (const byte[512]) mul_sqr1_lo#0 [phi:mul_tables_compare->mul_tables_compare::@1#1] -- pbuz1=pbuc1 + lda #mul_sqr1_lo + sta kc_sqr+1 jmp b1 - //SEG24 [12] phi from mul_tables_compare::@5 to mul_tables_compare::@1 [phi:mul_tables_compare::@5->mul_tables_compare::@1] - b1_from_b5: - //SEG25 [12] phi (byte) mul_tables_compare::i#10 = (byte) mul_tables_compare::i#1 [phi:mul_tables_compare::@5->mul_tables_compare::@1#0] -- register_copy + //SEG25 [12] phi from mul_tables_compare::@2 to mul_tables_compare::@1 [phi:mul_tables_compare::@2->mul_tables_compare::@1] + b1_from_b2: + //SEG26 [12] phi (byte*) mul_tables_compare::asm_sqr#2 = (byte*) mul_tables_compare::asm_sqr#1 [phi:mul_tables_compare::@2->mul_tables_compare::@1#0] -- register_copy + //SEG27 [12] phi (byte*) mul_tables_compare::kc_sqr#2 = (byte*) mul_tables_compare::kc_sqr#1 [phi:mul_tables_compare::@2->mul_tables_compare::@1#1] -- register_copy jmp b1 - //SEG26 mul_tables_compare::@1 + //SEG28 mul_tables_compare::@1 b1: - //SEG27 [13] if(*((const byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- pbuc1_derefidx_vbuxx_eq_pbuc2_derefidx_vbuxx_then_la1 - lda mul_sqr_lo,x - cmp asm_mul_sqr_lo,x + //SEG29 [13] if(*((byte*) mul_tables_compare::kc_sqr#2)==*((byte*) mul_tables_compare::asm_sqr#2)) goto mul_tables_compare::@2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) -- _deref_pbuz1_eq__deref_pbuz2_then_la1 + ldy #0 + lda (kc_sqr),y + ldy #0 + cmp (asm_sqr),y beq b2 - jmp b6 - //SEG28 mul_tables_compare::@6 - b6: - //SEG29 [14] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- _deref_pbuc1=vbuc2 - lda #2 - sta BGCOL - jmp b2 - //SEG30 mul_tables_compare::@2 - b2: - //SEG31 [15] if(*((const byte[512]) mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@3 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- pbuc1_derefidx_vbuxx_eq_pbuc2_derefidx_vbuxx_then_la1 - lda mul_sqr_hi+$100,x - cmp asm_mul_sqr_hi+$100,x - beq b3 - jmp b7 - //SEG32 mul_tables_compare::@7 - b7: - //SEG33 [16] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- _deref_pbuc1=vbuc2 - lda #2 - sta BGCOL jmp b3 - //SEG34 mul_tables_compare::@3 + //SEG30 mul_tables_compare::@3 b3: - //SEG35 [17] if(*((const byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@4 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- pbuc1_derefidx_vbuxx_eq_pbuc2_derefidx_vbuxx_then_la1 - lda mul_sqr_lo,x - cmp asm_mul_sqr_lo,x - beq b4 + //SEG31 [14] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) -- _deref_pbuc1=vbuc2 + lda #2 + sta BGCOL + //SEG32 [15] call print_cls param-assignment [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) + //SEG33 [54] phi from mul_tables_compare::@3 to print_cls [phi:mul_tables_compare::@3->print_cls] + print_cls_from_b3: + jsr print_cls + //SEG34 [16] phi from mul_tables_compare::@3 to mul_tables_compare::@6 [phi:mul_tables_compare::@3->mul_tables_compare::@6] + b6_from_b3: + jmp b6 + //SEG35 mul_tables_compare::@6 + b6: + //SEG36 [17] call print_str param-assignment [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 ] ) + //SEG37 [47] phi from mul_tables_compare::@6 to print_str [phi:mul_tables_compare::@6->print_str] + print_str_from_b6: + //SEG38 [47] phi (byte*) char_cursor#44 = ((byte*))(word/signed word) 1024 [phi:mul_tables_compare::@6->print_str#0] -- pbuz1=pbuc1 + lda #<$400 + sta char_cursor + lda #>$400 + sta char_cursor+1 + //SEG39 [47] phi (byte*) print_str::str#5 = (const string) mul_tables_compare::str [phi:mul_tables_compare::@6->print_str#1] -- pbuz1=pbuc1 + lda #str + sta print_str.str+1 + jsr print_str + jmp b7 + //SEG40 mul_tables_compare::@7 + b7: + //SEG41 [18] (word) print_word::w#0 ← ((word)) (byte*) mul_tables_compare::asm_sqr#2 [ mul_tables_compare::kc_sqr#2 print_word::w#0 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 print_word::w#0 char_cursor#19 ] ) -- vwuz1=_word_pbuz1 + //SEG42 [19] call print_word param-assignment [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] ) + //SEG43 [29] phi from mul_tables_compare::@7 to print_word [phi:mul_tables_compare::@7->print_word] + print_word_from_b7: + //SEG44 [29] phi (word) print_word::w#2 = (word) print_word::w#0 [phi:mul_tables_compare::@7->print_word#0] -- register_copy + jsr print_word + //SEG45 [20] phi from mul_tables_compare::@7 to mul_tables_compare::@8 [phi:mul_tables_compare::@7->mul_tables_compare::@8] + b8_from_b7: jmp b8 - //SEG36 mul_tables_compare::@8 + //SEG46 mul_tables_compare::@8 b8: - //SEG37 [18] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- _deref_pbuc1=vbuc2 - lda #2 - sta BGCOL - jmp b4 - //SEG38 mul_tables_compare::@4 - b4: - //SEG39 [19] if(*((const byte[512]) mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@5 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- pbuc1_derefidx_vbuxx_eq_pbuc2_derefidx_vbuxx_then_la1 - lda mul_sqr_hi+$100,x - cmp asm_mul_sqr_hi+$100,x - beq b5 + //SEG47 [21] call print_str param-assignment [ mul_tables_compare::kc_sqr#2 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 char_cursor#19 ] ) + //SEG48 [47] phi from mul_tables_compare::@8 to print_str [phi:mul_tables_compare::@8->print_str] + print_str_from_b8: + //SEG49 [47] phi (byte*) char_cursor#44 = (byte*) char_cursor#10 [phi:mul_tables_compare::@8->print_str#0] -- register_copy + //SEG50 [47] phi (byte*) print_str::str#5 = (const string) mul_tables_compare::str1 [phi:mul_tables_compare::@8->print_str#1] -- pbuz1=pbuc1 + lda #str1 + sta print_str.str+1 + jsr print_str jmp b9 - //SEG40 mul_tables_compare::@9 + //SEG51 mul_tables_compare::@9 b9: - //SEG41 [20] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- _deref_pbuc1=vbuc2 - lda #2 - sta BGCOL - jmp b5 - //SEG42 mul_tables_compare::@5 - b5: - //SEG43 [21] (byte) mul_tables_compare::i#1 ← ++ (byte) mul_tables_compare::i#10 [ mul_tables_compare::i#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#1 ] ) -- vbuxx=_inc_vbuxx - inx - //SEG44 [22] if((byte) mul_tables_compare::i#1!=(byte/signed byte/word/signed word) 0) goto mul_tables_compare::@1 [ mul_tables_compare::i#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#1 ] ) -- vbuxx_neq_0_then_la1 - cpx #0 - bne b1_from_b5 + //SEG52 [22] (word) print_word::w#1 ← ((word)) (byte*) mul_tables_compare::kc_sqr#2 [ print_word::w#1 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ print_word::w#1 char_cursor#19 ] ) -- vwuz1=_word_pbuz2 + lda kc_sqr + sta print_word.w + lda kc_sqr+1 + sta print_word.w+1 + //SEG53 [23] call print_word param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9 [ char_cursor#10 ] ) + //SEG54 [29] phi from mul_tables_compare::@9 to print_word [phi:mul_tables_compare::@9->print_word] + print_word_from_b9: + //SEG55 [29] phi (word) print_word::w#2 = (word) print_word::w#1 [phi:mul_tables_compare::@9->print_word#0] -- register_copy + jsr print_word + //SEG56 [24] phi from mul_tables_compare::@9 to mul_tables_compare::@return [phi:mul_tables_compare::@9->mul_tables_compare::@return] + breturn_from_b9: + //SEG57 [24] phi (byte*) char_cursor#17 = (byte*) char_cursor#10 [phi:mul_tables_compare::@9->mul_tables_compare::@return#0] -- register_copy jmp breturn - //SEG45 mul_tables_compare::@return + //SEG58 mul_tables_compare::@return breturn: - //SEG46 [23] return [ ] ( main:2::mul_tables_compare:9 [ ] ) + //SEG59 [25] return [ ] ( main:2::mul_tables_compare:9 [ ] ) + rts + //SEG60 mul_tables_compare::@2 + b2: + //SEG61 [26] (byte*) mul_tables_compare::asm_sqr#1 ← ++ (byte*) mul_tables_compare::asm_sqr#2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#1 ] ) -- pbuz1=_inc_pbuz1 + inc asm_sqr + bne !+ + inc asm_sqr+1 + !: + //SEG62 [27] (byte*) mul_tables_compare::kc_sqr#1 ← ++ (byte*) mul_tables_compare::kc_sqr#2 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ) -- pbuz1=_inc_pbuz1 + inc kc_sqr + bne !+ + inc kc_sqr+1 + !: + //SEG63 [28] if((byte*) mul_tables_compare::kc_sqr#1<(const byte[512]) mul_sqr1_lo#0+(word/signed word) 512*(byte/signed byte/word/signed word) 4) goto mul_tables_compare::@1 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ) -- pbuz1_lt_pbuc1_then_la1 + lda kc_sqr+1 + cmp #>mul_sqr1_lo+$200*4 + bcc b1_from_b2 + bne !+ + lda kc_sqr + cmp #mul_tables_compare::@return] + breturn_from_b2: + //SEG65 [24] phi (byte*) char_cursor#17 = ((byte*))(word/signed word) 1024 [phi:mul_tables_compare::@2->mul_tables_compare::@return#0] -- pbuz1=pbuc1 + lda #<$400 + sta char_cursor + lda #>$400 + sta char_cursor+1 + jmp breturn + str: .text "mul table mismatch at @" + str1: .text " / @" +} +//SEG66 print_word +print_word: { + .label w = 4 + //SEG67 [30] (byte) print_byte::b#0 ← > (word) print_word::w#2 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#0 char_cursor#19 ] main:2::mul_tables_compare:9::print_word:23 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ) -- vbuxx=_hi_vwuz1 + lda w+1 + tax + //SEG68 [31] call print_byte param-assignment [ char_cursor#10 print_word::w#2 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_word::w#2 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 print_word::w#2 ] ) + //SEG69 [35] phi from print_word to print_byte [phi:print_word->print_byte] + print_byte_from_print_word: + //SEG70 [35] phi (byte*) char_cursor#39 = (byte*) char_cursor#19 [phi:print_word->print_byte#0] -- register_copy + //SEG71 [35] phi (byte) print_byte::b#2 = (byte) print_byte::b#0 [phi:print_word->print_byte#1] -- register_copy + jsr print_byte + jmp b1 + //SEG72 print_word::@1 + b1: + //SEG73 [32] (byte) print_byte::b#1 ← < (word) print_word::w#2 [ char_cursor#10 print_byte::b#1 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::b#1 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 print_byte::b#1 ] ) -- vbuxx=_lo_vwuz1 + lda w + tax + //SEG74 [33] call print_byte param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 ] ) + //SEG75 [35] phi from print_word::@1 to print_byte [phi:print_word::@1->print_byte] + print_byte_from_b1: + //SEG76 [35] phi (byte*) char_cursor#39 = (byte*) char_cursor#10 [phi:print_word::@1->print_byte#0] -- register_copy + //SEG77 [35] phi (byte) print_byte::b#2 = (byte) print_byte::b#1 [phi:print_word::@1->print_byte#1] -- register_copy + jsr print_byte + jmp breturn + //SEG78 print_word::@return + breturn: + //SEG79 [34] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 ] ) rts } -//SEG47 init_mul_tables_asm +//SEG80 print_byte +print_byte: { + //SEG81 [36] (byte~) print_byte::$0 ← (byte) print_byte::b#2 >> (byte/signed byte/word/signed word) 4 [ print_byte::b#2 char_cursor#39 print_byte::$0 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 print_byte::$0 ] ) -- vbuyy=vbuxx_ror_4 + txa + lsr + lsr + lsr + lsr + tay + //SEG82 [37] (byte) print_char::ch#0 ← *((const byte[]) print_byte::hextab#0 + (byte~) print_byte::$0) [ print_byte::b#2 char_cursor#39 print_char::ch#0 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 print_char::ch#0 ] ) -- vbuaa=pbuc1_derefidx_vbuyy + lda hextab,y + //SEG83 [38] call print_char param-assignment [ char_cursor#10 print_byte::b#2 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_byte::b#2 ] ) + //SEG84 [43] phi from print_byte to print_char [phi:print_byte->print_char] + print_char_from_print_byte: + //SEG85 [43] phi (byte*) char_cursor#27 = (byte*) char_cursor#39 [phi:print_byte->print_char#0] -- register_copy + //SEG86 [43] phi (byte) print_char::ch#2 = (byte) print_char::ch#0 [phi:print_byte->print_char#1] -- register_copy + jsr print_char + jmp b1 + //SEG87 print_byte::@1 + b1: + //SEG88 [39] (byte~) print_byte::$2 ← (byte) print_byte::b#2 & (byte/signed byte/word/signed word) 15 [ char_cursor#10 print_byte::$2 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_byte::$2 ] ) -- vbuaa=vbuxx_band_vbuc1 + txa + and #$f + //SEG89 [40] (byte) print_char::ch#1 ← *((const byte[]) print_byte::hextab#0 + (byte~) print_byte::$2) [ char_cursor#10 print_char::ch#1 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_char::ch#1 ] ) -- vbuaa=pbuc1_derefidx_vbuaa + tax + lda hextab,x + //SEG90 [41] call print_char param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 ] ) + //SEG91 [43] phi from print_byte::@1 to print_char [phi:print_byte::@1->print_char] + print_char_from_b1: + //SEG92 [43] phi (byte*) char_cursor#27 = (byte*) char_cursor#10 [phi:print_byte::@1->print_char#0] -- register_copy + //SEG93 [43] phi (byte) print_char::ch#2 = (byte) print_char::ch#1 [phi:print_byte::@1->print_char#1] -- register_copy + jsr print_char + jmp breturn + //SEG94 print_byte::@return + breturn: + //SEG95 [42] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 ] ) + rts + hextab: .byte '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f' +} +//SEG96 print_char +print_char: { + //SEG97 [44] *((byte*) char_cursor#27) ← (byte) print_char::ch#2 [ char_cursor#27 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#27 ] ) -- _deref_pbuz1=vbuaa + ldy #0 + sta (char_cursor),y + //SEG98 [45] (byte*) char_cursor#10 ← ++ (byte*) char_cursor#27 [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#10 ] ) -- pbuz1=_inc_pbuz1 + inc char_cursor + bne !+ + inc char_cursor+1 + !: + jmp breturn + //SEG99 print_char::@return + breturn: + //SEG100 [46] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#10 ] ) + rts +} +//SEG101 print_str +print_str: { + .label str = 8 + //SEG102 [48] phi from print_str print_str::@2 to print_str::@1 [phi:print_str/print_str::@2->print_str::@1] + b1_from_print_str: + b1_from_b2: + //SEG103 [48] phi (byte*) char_cursor#19 = (byte*) char_cursor#44 [phi:print_str/print_str::@2->print_str::@1#0] -- register_copy + //SEG104 [48] phi (byte*) print_str::str#3 = (byte*) print_str::str#5 [phi:print_str/print_str::@2->print_str::@1#1] -- register_copy + jmp b1 + //SEG105 print_str::@1 + b1: + //SEG106 [49] if(*((byte*) print_str::str#3)!=(byte) '@') goto print_str::@2 [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) -- _deref_pbuz1_neq_vbuc1_then_la1 + ldy #0 + lda (str),y + cmp #'@' + bne b2 + jmp breturn + //SEG107 print_str::@return + breturn: + //SEG108 [50] return [ char_cursor#19 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 ] ) + rts + //SEG109 print_str::@2 + b2: + //SEG110 [51] *((byte*) char_cursor#19) ← *((byte*) print_str::str#3) [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) -- _deref_pbuz1=_deref_pbuz2 + ldy #0 + lda (str),y + ldy #0 + sta (char_cursor),y + //SEG111 [52] (byte*) char_cursor#1 ← ++ (byte*) char_cursor#19 [ print_str::str#3 char_cursor#1 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#3 char_cursor#1 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#3 char_cursor#1 ] ) -- pbuz1=_inc_pbuz1 + inc char_cursor + bne !+ + inc char_cursor+1 + !: + //SEG112 [53] (byte*) print_str::str#0 ← ++ (byte*) print_str::str#3 [ print_str::str#0 char_cursor#1 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#0 char_cursor#1 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#0 char_cursor#1 ] ) -- pbuz1=_inc_pbuz1 + inc str + bne !+ + inc str+1 + !: + jmp b1_from_b2 +} +//SEG113 print_cls +print_cls: { + .label sc = 6 + //SEG114 [55] phi from print_cls to print_cls::@1 [phi:print_cls->print_cls::@1] + b1_from_print_cls: + //SEG115 [55] phi (byte*) print_cls::sc#2 = ((byte*))(word/signed word) 1024 [phi:print_cls->print_cls::@1#0] -- pbuz1=pbuc1 + lda #<$400 + sta sc + lda #>$400 + sta sc+1 + jmp b1 + //SEG116 [55] phi from print_cls::@1 to print_cls::@1 [phi:print_cls::@1->print_cls::@1] + b1_from_b1: + //SEG117 [55] phi (byte*) print_cls::sc#2 = (byte*) print_cls::sc#1 [phi:print_cls::@1->print_cls::@1#0] -- register_copy + jmp b1 + //SEG118 print_cls::@1 + b1: + //SEG119 [56] *((byte*) print_cls::sc#2) ← (byte) ' ' [ print_cls::sc#2 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#2 ] ) -- _deref_pbuz1=vbuc1 + ldy #0 + lda #' ' + sta (sc),y + //SEG120 [57] (byte*) print_cls::sc#1 ← ++ (byte*) print_cls::sc#2 [ print_cls::sc#1 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#1 ] ) -- pbuz1=_inc_pbuz1 + inc sc + bne !+ + inc sc+1 + !: + //SEG121 [58] if((byte*) print_cls::sc#1!=(word/signed word) 1024+(word/signed word) 1000) goto print_cls::@1 [ print_cls::sc#1 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#1 ] ) -- pbuz1_neq_vwuc1_then_la1 + lda sc+1 + cmp #>$400+$3e8 + bne b1_from_b1 + lda sc + cmp #<$400+$3e8 + bne b1_from_b1 + jmp breturn + //SEG122 print_cls::@return + breturn: + //SEG123 [59] return [ ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) + rts +} +//SEG124 init_mul_tables_asm init_mul_tables_asm: { - //SEG48 asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr_lo,xbnelb1incml0+2incml1+2clcinybnelb1 } + .const mem = $ff + //SEG125 asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr1_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr1_lo,xbnelb1incml0+2incml1+2clcinybnelb1ldx#$00ldy#$ff!:ldaasm_mul_sqr1_hi+1,xstaasm_mul_sqr2_hi+$100,xldaasm_mul_sqr1_hi,xstaasm_mul_sqr2_hi,yldaasm_mul_sqr1_lo+1,xstaasm_mul_sqr2_lo+$100,xldaasm_mul_sqr1_lo,xstaasm_mul_sqr2_lo,ydeyinxbne!- } ldx #0 txa .byte $c9 @@ -1531,7 +3649,7 @@ init_mul_tables_asm: { tya adc #0 ml1: - sta asm_mul_sqr_hi,x + sta asm_mul_sqr1_hi,x tay cmp #$40 txa @@ -1541,100 +3659,129 @@ init_mul_tables_asm: { sta ml9+1 inx ml0: - sta asm_mul_sqr_lo,x + sta asm_mul_sqr1_lo,x bne lb1 inc ml0+2 inc ml1+2 clc iny bne lb1 + ldx #0 + ldy #$ff + !: + lda asm_mul_sqr1_hi+1,x + sta asm_mul_sqr2_hi+$100,x + lda asm_mul_sqr1_hi,x + sta asm_mul_sqr2_hi,y + lda asm_mul_sqr1_lo+1,x + sta asm_mul_sqr2_lo+$100,x + lda asm_mul_sqr1_lo,x + sta asm_mul_sqr2_lo,y + dey + inx + bne !- + //SEG126 [61] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) -- _deref_pbuc1=_deref_pbuc2 + lda asm_mul_sqr1_lo + sta mem + //SEG127 [62] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) -- _deref_pbuc1=_deref_pbuc2 + lda asm_mul_sqr1_hi + sta mem + //SEG128 [63] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) -- _deref_pbuc1=_deref_pbuc2 + lda asm_mul_sqr2_lo + sta mem + //SEG129 [64] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) -- _deref_pbuc1=_deref_pbuc2 + lda asm_mul_sqr2_hi + sta mem jmp breturn - //SEG49 init_mul_tables_asm::@return + //SEG130 init_mul_tables_asm::@return breturn: - //SEG50 [25] return [ ] ( main:2::init_mul_tables_asm:7 [ ] ) + //SEG131 [65] return [ ] ( main:2::init_mul_tables_asm:7 [ ] ) rts } -//SEG51 init_mul_tables +//SEG132 init_mul_tables init_mul_tables: { - .label sqr_hi = 4 - .label sqr = 7 - .label sqr_lo = 2 - .label x_2 = 6 - //SEG52 [27] phi from init_mul_tables to init_mul_tables::@1 [phi:init_mul_tables->init_mul_tables::@1] + .label sqr1_hi = 4 + .label sqr = 6 + .label sqr1_lo = 2 + .label x_2 = $a + .label sqr2_hi = 4 + .label sqr2_lo = 2 + .label dir = $a + //SEG133 [67] phi from init_mul_tables to init_mul_tables::@1 [phi:init_mul_tables->init_mul_tables::@1] b1_from_init_mul_tables: - //SEG53 [27] phi (byte) init_mul_tables::x_2#3 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#0] -- vbuz1=vbuc1 + //SEG134 [67] phi (byte) init_mul_tables::x_2#3 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#0] -- vbuz1=vbuc1 lda #0 sta x_2 - //SEG54 [27] phi (byte*) init_mul_tables::sqr_hi#2 = (const byte[512]) mul_sqr_hi#0+(byte/signed byte/word/signed word) 1 [phi:init_mul_tables->init_mul_tables::@1#1] -- pbuz1=pbuc1 - lda #mul_sqr_hi+1 - sta sqr_hi+1 - //SEG55 [27] phi (byte*) init_mul_tables::sqr_lo#2 = (const byte[512]) mul_sqr_lo#0+(byte/signed byte/word/signed word) 1 [phi:init_mul_tables->init_mul_tables::@1#2] -- pbuz1=pbuc1 - lda #mul_sqr_lo+1 - sta sqr_lo+1 - //SEG56 [27] phi (word) init_mul_tables::sqr#4 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#3] -- vwuz1=vbuc1 + //SEG135 [67] phi (byte*) init_mul_tables::sqr1_hi#2 = (const byte[512]) mul_sqr1_hi#0+(byte/signed byte/word/signed word) 1 [phi:init_mul_tables->init_mul_tables::@1#1] -- pbuz1=pbuc1 + lda #mul_sqr1_hi+1 + sta sqr1_hi+1 + //SEG136 [67] phi (byte*) init_mul_tables::sqr1_lo#2 = (const byte[512]) mul_sqr1_lo#0+(byte/signed byte/word/signed word) 1 [phi:init_mul_tables->init_mul_tables::@1#2] -- pbuz1=pbuc1 + lda #mul_sqr1_lo+1 + sta sqr1_lo+1 + //SEG137 [67] phi (word) init_mul_tables::sqr#4 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#3] -- vwuz1=vbuc1 lda #0 sta sqr lda #0 sta sqr+1 - //SEG57 [27] phi (byte) init_mul_tables::c#2 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#4] -- vbuxx=vbuc1 + //SEG138 [67] phi (byte) init_mul_tables::c#2 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#4] -- vbuxx=vbuc1 ldx #0 jmp b1 - //SEG58 [27] phi from init_mul_tables::@2 to init_mul_tables::@1 [phi:init_mul_tables::@2->init_mul_tables::@1] + //SEG139 [67] phi from init_mul_tables::@2 to init_mul_tables::@1 [phi:init_mul_tables::@2->init_mul_tables::@1] b1_from_b2: - //SEG59 [27] phi (byte) init_mul_tables::x_2#3 = (byte) init_mul_tables::x_2#2 [phi:init_mul_tables::@2->init_mul_tables::@1#0] -- register_copy - //SEG60 [27] phi (byte*) init_mul_tables::sqr_hi#2 = (byte*) init_mul_tables::sqr_hi#1 [phi:init_mul_tables::@2->init_mul_tables::@1#1] -- register_copy - //SEG61 [27] phi (byte*) init_mul_tables::sqr_lo#2 = (byte*) init_mul_tables::sqr_lo#1 [phi:init_mul_tables::@2->init_mul_tables::@1#2] -- register_copy - //SEG62 [27] phi (word) init_mul_tables::sqr#4 = (word) init_mul_tables::sqr#1 [phi:init_mul_tables::@2->init_mul_tables::@1#3] -- register_copy - //SEG63 [27] phi (byte) init_mul_tables::c#2 = (byte) init_mul_tables::c#1 [phi:init_mul_tables::@2->init_mul_tables::@1#4] -- register_copy + //SEG140 [67] phi (byte) init_mul_tables::x_2#3 = (byte) init_mul_tables::x_2#2 [phi:init_mul_tables::@2->init_mul_tables::@1#0] -- register_copy + //SEG141 [67] phi (byte*) init_mul_tables::sqr1_hi#2 = (byte*) init_mul_tables::sqr1_hi#1 [phi:init_mul_tables::@2->init_mul_tables::@1#1] -- register_copy + //SEG142 [67] phi (byte*) init_mul_tables::sqr1_lo#2 = (byte*) init_mul_tables::sqr1_lo#1 [phi:init_mul_tables::@2->init_mul_tables::@1#2] -- register_copy + //SEG143 [67] phi (word) init_mul_tables::sqr#4 = (word) init_mul_tables::sqr#1 [phi:init_mul_tables::@2->init_mul_tables::@1#3] -- register_copy + //SEG144 [67] phi (byte) init_mul_tables::c#2 = (byte) init_mul_tables::c#1 [phi:init_mul_tables::@2->init_mul_tables::@1#4] -- register_copy jmp b1 - //SEG64 init_mul_tables::@1 + //SEG145 init_mul_tables::@1 b1: - //SEG65 [28] (byte) init_mul_tables::c#1 ← ++ (byte) init_mul_tables::c#2 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) -- vbuxx=_inc_vbuxx + //SEG146 [68] (byte) init_mul_tables::c#1 ← ++ (byte) init_mul_tables::c#2 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) -- vbuxx=_inc_vbuxx inx - //SEG66 [29] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) -- vbuaa=vbuxx_band_vbuc1 + //SEG147 [69] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) -- vbuaa=vbuxx_band_vbuc1 txa and #1 - //SEG67 [30] if((byte~) init_mul_tables::$2!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@2 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) -- vbuaa_neq_0_then_la1 + //SEG148 [70] if((byte~) init_mul_tables::$2!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@2 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) -- vbuaa_neq_0_then_la1 cmp #0 bne b2_from_b1 - jmp b3 - //SEG68 init_mul_tables::@3 - b3: - //SEG69 [31] (byte) init_mul_tables::x_2#1 ← ++ (byte) init_mul_tables::x_2#3 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ) -- vbuz1=_inc_vbuz1 + jmp b5 + //SEG149 init_mul_tables::@5 + b5: + //SEG150 [71] (byte) init_mul_tables::x_2#1 ← ++ (byte) init_mul_tables::x_2#3 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ) -- vbuz1=_inc_vbuz1 inc x_2 - //SEG70 [32] (word) init_mul_tables::sqr#2 ← ++ (word) init_mul_tables::sqr#4 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ) -- vwuz1=_inc_vwuz1 + //SEG151 [72] (word) init_mul_tables::sqr#2 ← ++ (word) init_mul_tables::sqr#4 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ) -- vwuz1=_inc_vwuz1 inc sqr bne !+ inc sqr+1 !: - //SEG71 [33] phi from init_mul_tables::@1 init_mul_tables::@3 to init_mul_tables::@2 [phi:init_mul_tables::@1/init_mul_tables::@3->init_mul_tables::@2] + //SEG152 [73] phi from init_mul_tables::@1 init_mul_tables::@5 to init_mul_tables::@2 [phi:init_mul_tables::@1/init_mul_tables::@5->init_mul_tables::@2] b2_from_b1: - b2_from_b3: - //SEG72 [33] phi (byte) init_mul_tables::x_2#2 = (byte) init_mul_tables::x_2#3 [phi:init_mul_tables::@1/init_mul_tables::@3->init_mul_tables::@2#0] -- register_copy - //SEG73 [33] phi (word) init_mul_tables::sqr#3 = (word) init_mul_tables::sqr#4 [phi:init_mul_tables::@1/init_mul_tables::@3->init_mul_tables::@2#1] -- register_copy + b2_from_b5: + //SEG153 [73] phi (byte) init_mul_tables::x_2#2 = (byte) init_mul_tables::x_2#3 [phi:init_mul_tables::@1/init_mul_tables::@5->init_mul_tables::@2#0] -- register_copy + //SEG154 [73] phi (word) init_mul_tables::sqr#3 = (word) init_mul_tables::sqr#4 [phi:init_mul_tables::@1/init_mul_tables::@5->init_mul_tables::@2#1] -- register_copy jmp b2 - //SEG74 init_mul_tables::@2 + //SEG155 init_mul_tables::@2 b2: - //SEG75 [34] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) -- vbuaa=_lo_vwuz1 + //SEG156 [74] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) -- vbuaa=_lo_vwuz1 lda sqr - //SEG76 [35] *((byte*) init_mul_tables::sqr_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- _deref_pbuz1=vbuaa + //SEG157 [75] *((byte*) init_mul_tables::sqr1_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- _deref_pbuz1=vbuaa ldy #0 - sta (sqr_lo),y - //SEG77 [36] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) -- vbuaa=_hi_vwuz1 + sta (sqr1_lo),y + //SEG158 [76] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) -- vbuaa=_hi_vwuz1 lda sqr+1 - //SEG78 [37] *((byte*) init_mul_tables::sqr_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- _deref_pbuz1=vbuaa + //SEG159 [77] *((byte*) init_mul_tables::sqr1_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- _deref_pbuz1=vbuaa ldy #0 - sta (sqr_hi),y - //SEG79 [38] (byte*) init_mul_tables::sqr_hi#1 ← ++ (byte*) init_mul_tables::sqr_hi#2 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- pbuz1=_inc_pbuz1 - inc sqr_hi + sta (sqr1_hi),y + //SEG160 [78] (byte*) init_mul_tables::sqr1_hi#1 ← ++ (byte*) init_mul_tables::sqr1_hi#2 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- pbuz1=_inc_pbuz1 + inc sqr1_hi bne !+ - inc sqr_hi+1 + inc sqr1_hi+1 !: - //SEG80 [39] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) -- vwuz1=vwuz1_plus_vbuz2 + //SEG161 [79] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) -- vwuz1=vwuz1_plus_vbuz2 lda x_2 clc adc sqr @@ -1642,154 +3789,379 @@ init_mul_tables: { bcc !+ inc sqr+1 !: - //SEG81 [40] (byte*) init_mul_tables::sqr_lo#1 ← ++ (byte*) init_mul_tables::sqr_lo#2 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) -- pbuz1=_inc_pbuz1 - inc sqr_lo + //SEG162 [80] (byte*) init_mul_tables::sqr1_lo#1 ← ++ (byte*) init_mul_tables::sqr1_lo#2 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) -- pbuz1=_inc_pbuz1 + inc sqr1_lo bne !+ - inc sqr_lo+1 + inc sqr1_lo+1 !: - //SEG82 [41] if((byte*) init_mul_tables::sqr_lo#1!=(const byte[512]) mul_sqr_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) -- pbuz1_neq_pbuc1_then_la1 - lda sqr_lo+1 - cmp #>mul_sqr_lo+$200 + //SEG163 [81] if((byte*) init_mul_tables::sqr1_lo#1!=(const byte[512]) mul_sqr1_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) -- pbuz1_neq_pbuc1_then_la1 + lda sqr1_lo+1 + cmp #>mul_sqr1_lo+$200 bne b1_from_b2 - lda sqr_lo - cmp #init_mul_tables::@3] + b3_from_b2: + //SEG165 [82] phi (byte) init_mul_tables::dir#2 = (byte/word/signed word) 255 [phi:init_mul_tables::@2->init_mul_tables::@3#0] -- vbuz1=vbuc1 + lda #$ff + sta dir + //SEG166 [82] phi (byte*) init_mul_tables::sqr2_hi#2 = (const byte[512]) mul_sqr2_hi#0 [phi:init_mul_tables::@2->init_mul_tables::@3#1] -- pbuz1=pbuc1 + lda #mul_sqr2_hi + sta sqr2_hi+1 + //SEG167 [82] phi (byte*) init_mul_tables::sqr2_lo#2 = (const byte[512]) mul_sqr2_lo#0 [phi:init_mul_tables::@2->init_mul_tables::@3#2] -- pbuz1=pbuc1 + lda #mul_sqr2_lo + sta sqr2_lo+1 + //SEG168 [82] phi (byte) init_mul_tables::x_255#2 = ((byte))-(byte/signed byte/word/signed word) 1 [phi:init_mul_tables::@2->init_mul_tables::@3#3] -- vbuxx=vbuc1 + ldx #-1 + jmp b3 + //SEG169 [82] phi from init_mul_tables::@4 to init_mul_tables::@3 [phi:init_mul_tables::@4->init_mul_tables::@3] + b3_from_b4: + //SEG170 [82] phi (byte) init_mul_tables::dir#2 = (byte) init_mul_tables::dir#3 [phi:init_mul_tables::@4->init_mul_tables::@3#0] -- register_copy + //SEG171 [82] phi (byte*) init_mul_tables::sqr2_hi#2 = (byte*) init_mul_tables::sqr2_hi#1 [phi:init_mul_tables::@4->init_mul_tables::@3#1] -- register_copy + //SEG172 [82] phi (byte*) init_mul_tables::sqr2_lo#2 = (byte*) init_mul_tables::sqr2_lo#1 [phi:init_mul_tables::@4->init_mul_tables::@3#2] -- register_copy + //SEG173 [82] phi (byte) init_mul_tables::x_255#2 = (byte) init_mul_tables::x_255#1 [phi:init_mul_tables::@4->init_mul_tables::@3#3] -- register_copy + jmp b3 + //SEG174 init_mul_tables::@3 + b3: + //SEG175 [83] *((byte*) init_mul_tables::sqr2_lo#2) ← *((const byte[512]) mul_sqr1_lo#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) -- _deref_pbuz1=pbuc1_derefidx_vbuxx + lda mul_sqr1_lo,x + ldy #0 + sta (sqr2_lo),y + //SEG176 [84] *((byte*) init_mul_tables::sqr2_hi#2) ← *((const byte[512]) mul_sqr1_hi#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) -- _deref_pbuz1=pbuc1_derefidx_vbuxx + lda mul_sqr1_hi,x + ldy #0 + sta (sqr2_hi),y + //SEG177 [85] (byte*) init_mul_tables::sqr2_hi#1 ← ++ (byte*) init_mul_tables::sqr2_hi#2 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::sqr2_hi#1 ] ) -- pbuz1=_inc_pbuz1 + inc sqr2_hi + bne !+ + inc sqr2_hi+1 + !: + //SEG178 [86] (byte) init_mul_tables::x_255#1 ← (byte) init_mul_tables::x_255#2 + (byte) init_mul_tables::dir#2 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) -- vbuxx=vbuxx_plus_vbuz1 + txa + clc + adc dir + tax + //SEG179 [87] if((byte) init_mul_tables::x_255#1!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@12 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) -- vbuxx_neq_0_then_la1 + cpx #0 + bne b12_from_b3 + //SEG180 [88] phi from init_mul_tables::@3 to init_mul_tables::@4 [phi:init_mul_tables::@3->init_mul_tables::@4] + b4_from_b3: + //SEG181 [88] phi (byte) init_mul_tables::dir#3 = (byte/signed byte/word/signed word) 1 [phi:init_mul_tables::@3->init_mul_tables::@4#0] -- vbuz1=vbuc1 + lda #1 + sta dir + jmp b4 + //SEG182 init_mul_tables::@4 + b4: + //SEG183 [89] (byte*) init_mul_tables::sqr2_lo#1 ← ++ (byte*) init_mul_tables::sqr2_lo#2 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) -- pbuz1=_inc_pbuz1 + inc sqr2_lo + bne !+ + inc sqr2_lo+1 + !: + //SEG184 [90] if((byte*) init_mul_tables::sqr2_lo#1!=(const byte[512]) mul_sqr2_lo#0+(word/signed word) 511) goto init_mul_tables::@3 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) -- pbuz1_neq_pbuc1_then_la1 + lda sqr2_lo+1 + cmp #>mul_sqr2_lo+$1ff + bne b3_from_b4 + lda sqr2_lo + cmp #init_mul_tables::@12] + b12_from_b3: + jmp b12 + //SEG191 init_mul_tables::@12 + b12: + //SEG192 [88] phi from init_mul_tables::@12 to init_mul_tables::@4 [phi:init_mul_tables::@12->init_mul_tables::@4] + b4_from_b12: + //SEG193 [88] phi (byte) init_mul_tables::dir#3 = (byte) init_mul_tables::dir#2 [phi:init_mul_tables::@12->init_mul_tables::@4#0] -- register_copy + jmp b4 } ASSEMBLER OPTIMIZATIONS -Removing instruction jmp b4 +Removing instruction jmp b10 Removing instruction jmp bend Removing instruction jmp b1 Removing instruction jmp b2 Removing instruction jmp breturn Removing instruction jmp b1 -Removing instruction jmp b6 -Removing instruction jmp b2 -Removing instruction jmp b7 Removing instruction jmp b3 +Removing instruction jmp b6 +Removing instruction jmp b7 Removing instruction jmp b8 -Removing instruction jmp b4 Removing instruction jmp b9 -Removing instruction jmp b5 +Removing instruction jmp breturn +Removing instruction jmp b1 +Removing instruction jmp breturn +Removing instruction jmp b1 Removing instruction jmp breturn Removing instruction jmp breturn Removing instruction jmp b1 -Removing instruction jmp b3 -Removing instruction jmp b2 Removing instruction jmp breturn +Removing instruction jmp b1 +Removing instruction jmp breturn +Removing instruction jmp breturn +Removing instruction jmp b1 +Removing instruction jmp b5 +Removing instruction jmp b2 +Removing instruction jmp b3 +Removing instruction jmp b4 +Removing instruction jmp b8 +Removing instruction jmp breturn +Removing instruction jmp b12 Succesful ASM optimization Pass5NextJumpElimination +Removing instruction ldy #0 +Removing instruction ldy #0 Removing instruction lda #0 Replacing instruction ldx #0 with TAX Removing instruction ldy #0 +Removing instruction ldy #0 Succesful ASM optimization Pass5UnnecesaryLoadElimination -Replacing label b1_from_b5 with b1 +Replacing label b1_from_b2 with b1 +Replacing label b1_from_b2 with b1 +Replacing label b1_from_b2 with b1 +Replacing label b1_from_b1 with b1 +Replacing label b1_from_b1 with b1 Replacing label b2_from_b1 with b2 Replacing label b1_from_b2 with b1 Replacing label b1_from_b2 with b1 +Replacing label b12_from_b3 with b12 +Replacing label b3_from_b4 with b3 +Replacing label b3_from_b4 with b3 Removing instruction bbegin: -Removing instruction b4_from_bbegin: -Removing instruction main_from_b4: -Removing instruction bend_from_b4: +Removing instruction b10_from_bbegin: +Removing instruction main_from_b10: +Removing instruction bend_from_b10: Removing instruction b1_from_main: Removing instruction b2_from_b1: -Removing instruction b1_from_b5: +Removing instruction b1_from_b2: +Removing instruction b6_from_b3: +Removing instruction print_str_from_b6: +Removing instruction print_word_from_b7: +Removing instruction b8_from_b7: +Removing instruction print_str_from_b8: +Removing instruction breturn_from_b9: +Removing instruction b1_from_print_str: +Removing instruction b1_from_b2: +Removing instruction b1_from_b1: Removing instruction b1_from_b2: Removing instruction b2_from_b1: -Removing instruction b2_from_b3: +Removing instruction b2_from_b5: +Removing instruction b3_from_b4: +Removing instruction b12_from_b3: +Removing instruction b4_from_b12: Succesful ASM optimization Pass5RedundantLabelElimination -Removing instruction b4: +Removing instruction b10: Removing instruction bend: Removing instruction init_mul_tables_from_main: Removing instruction b1: Removing instruction b2: Removing instruction breturn: Removing instruction b1_from_mul_tables_compare: +Removing instruction b3: +Removing instruction print_cls_from_b3: Removing instruction b6: Removing instruction b7: Removing instruction b8: Removing instruction b9: +Removing instruction print_word_from_b9: +Removing instruction breturn_from_b2: +Removing instruction print_byte_from_print_word: +Removing instruction b1: +Removing instruction print_byte_from_b1: +Removing instruction breturn: +Removing instruction print_char_from_print_byte: +Removing instruction b1: +Removing instruction print_char_from_b1: +Removing instruction breturn: +Removing instruction breturn: +Removing instruction breturn: +Removing instruction b1_from_print_cls: Removing instruction breturn: Removing instruction breturn: Removing instruction b1_from_init_mul_tables: -Removing instruction b3: +Removing instruction b5: +Removing instruction b3_from_b2: +Removing instruction b4_from_b3: +Removing instruction b8: Removing instruction breturn: Succesful ASM optimization Pass5UnusedLabelElimination +Skipping double jump to b4 in bne b12 +Succesful ASM optimization Pass5DoubleJumpElimination Removing instruction jmp b1 Removing instruction jmp b1 +Removing instruction jmp b1 +Removing instruction jmp b3 Succesful ASM optimization Pass5NextJumpElimination +Removing instruction b12: +Succesful ASM optimization Pass5UnusedLabelElimination +Removing unreachable instruction jmp b4 +Succesful ASM optimization Pass5UnreachableCodeElimination FINAL SYMBOL TABLE -(label) @4 +(label) @10 (label) @begin (label) @end (byte*) BGCOL (const byte*) BGCOL#0 BGCOL = ((byte*))(word) 53281 -(byte[512]) asm_mul_sqr_hi -(const byte[512]) asm_mul_sqr_hi#0 asm_mul_sqr_hi = { fill( 512, 0) } -(byte[512]) asm_mul_sqr_lo -(const byte[512]) asm_mul_sqr_lo#0 asm_mul_sqr_lo = { fill( 512, 0) } +(byte[512]) asm_mul_sqr1_hi +(const byte[512]) asm_mul_sqr1_hi#0 asm_mul_sqr1_hi = { fill( 512, 0) } +(byte[512]) asm_mul_sqr1_lo +(const byte[512]) asm_mul_sqr1_lo#0 asm_mul_sqr1_lo = { fill( 512, 0) } +(byte[512]) asm_mul_sqr2_hi +(const byte[512]) asm_mul_sqr2_hi#0 asm_mul_sqr2_hi = { fill( 512, 0) } +(byte[512]) asm_mul_sqr2_lo +(const byte[512]) asm_mul_sqr2_lo#0 asm_mul_sqr2_lo = { fill( 512, 0) } +(byte*) char_cursor +(byte*) char_cursor#1 char_cursor zp ZP_WORD:6 11.0 +(byte*) char_cursor#10 char_cursor zp ZP_WORD:6 0.7142857142857142 +(byte*) char_cursor#17 char_cursor zp ZP_WORD:6 20.0 +(byte*) char_cursor#19 char_cursor zp ZP_WORD:6 3.7 +(byte*) char_cursor#27 char_cursor zp ZP_WORD:6 4.0 +(byte*) char_cursor#39 char_cursor zp ZP_WORD:6 2.0 +(byte*) char_cursor#44 char_cursor zp ZP_WORD:6 4.0 (void()) init_mul_tables() (byte~) init_mul_tables::$2 reg byte a 22.0 (byte~) init_mul_tables::$5 reg byte a 22.0 (byte~) init_mul_tables::$6 reg byte a 22.0 (label) init_mul_tables::@1 +(label) init_mul_tables::@12 (label) init_mul_tables::@2 (label) init_mul_tables::@3 +(label) init_mul_tables::@4 +(label) init_mul_tables::@5 +(label) init_mul_tables::@8 (label) init_mul_tables::@return (byte) init_mul_tables::c (byte) init_mul_tables::c#1 reg byte x 2.357142857142857 (byte) init_mul_tables::c#2 reg byte x 22.0 +(byte) init_mul_tables::dir +(byte) init_mul_tables::dir#2 dir zp ZP_BYTE:10 4.714285714285714 +(byte) init_mul_tables::dir#3 dir zp ZP_BYTE:10 7.333333333333333 (word) init_mul_tables::sqr -(word) init_mul_tables::sqr#1 sqr zp ZP_WORD:7 7.333333333333333 -(word) init_mul_tables::sqr#2 sqr zp ZP_WORD:7 22.0 -(word) init_mul_tables::sqr#3 sqr zp ZP_WORD:7 9.166666666666666 -(word) init_mul_tables::sqr#4 sqr zp ZP_WORD:7 6.6000000000000005 -(byte*) init_mul_tables::sqr_hi -(byte*) init_mul_tables::sqr_hi#1 sqr_hi zp ZP_WORD:4 5.5 -(byte*) init_mul_tables::sqr_hi#2 sqr_hi zp ZP_WORD:4 3.0 -(byte*) init_mul_tables::sqr_lo -(byte*) init_mul_tables::sqr_lo#1 sqr_lo zp ZP_WORD:2 16.5 -(byte*) init_mul_tables::sqr_lo#2 sqr_lo zp ZP_WORD:2 2.5384615384615383 +(word) init_mul_tables::sqr#1 sqr zp ZP_WORD:6 7.333333333333333 +(word) init_mul_tables::sqr#2 sqr zp ZP_WORD:6 22.0 +(word) init_mul_tables::sqr#3 sqr zp ZP_WORD:6 9.166666666666666 +(word) init_mul_tables::sqr#4 sqr zp ZP_WORD:6 6.6000000000000005 +(byte*) init_mul_tables::sqr1_hi +(byte*) init_mul_tables::sqr1_hi#1 sqr1_hi zp ZP_WORD:4 5.5 +(byte*) init_mul_tables::sqr1_hi#2 sqr1_hi zp ZP_WORD:4 3.0 +(byte*) init_mul_tables::sqr1_lo +(byte*) init_mul_tables::sqr1_lo#1 sqr1_lo zp ZP_WORD:2 16.5 +(byte*) init_mul_tables::sqr1_lo#2 sqr1_lo zp ZP_WORD:2 2.5384615384615383 +(byte*) init_mul_tables::sqr2_hi +(byte*) init_mul_tables::sqr2_hi#1 sqr2_hi zp ZP_WORD:4 3.142857142857143 +(byte*) init_mul_tables::sqr2_hi#2 sqr2_hi zp ZP_WORD:4 11.0 +(byte*) init_mul_tables::sqr2_lo +(byte*) init_mul_tables::sqr2_lo#1 sqr2_lo zp ZP_WORD:2 16.5 +(byte*) init_mul_tables::sqr2_lo#2 sqr2_lo zp ZP_WORD:2 4.125 (byte) init_mul_tables::x_2 -(byte) init_mul_tables::x_2#1 x_2 zp ZP_BYTE:6 11.0 -(byte) init_mul_tables::x_2#2 x_2 zp ZP_BYTE:6 4.888888888888889 -(byte) init_mul_tables::x_2#3 x_2 zp ZP_BYTE:6 8.25 +(byte) init_mul_tables::x_2#1 x_2 zp ZP_BYTE:10 11.0 +(byte) init_mul_tables::x_2#2 x_2 zp ZP_BYTE:10 4.888888888888889 +(byte) init_mul_tables::x_2#3 x_2 zp ZP_BYTE:10 8.25 +(byte) init_mul_tables::x_255 +(byte) init_mul_tables::x_255#1 reg byte x 5.5 +(byte) init_mul_tables::x_255#2 reg byte x 11.0 (void()) init_mul_tables_asm() (label) init_mul_tables_asm::@return +(byte*) init_mul_tables_asm::mem +(const byte*) init_mul_tables_asm::mem#0 mem = ((byte*))(byte/word/signed word) 255 +(byte*) line_cursor (void()) main() (label) main::@1 (label) main::@2 (label) main::@return -(byte[512]) mul_sqr_hi -(const byte[512]) mul_sqr_hi#0 mul_sqr_hi = { fill( 512, 0) } -(byte[512]) mul_sqr_lo -(const byte[512]) mul_sqr_lo#0 mul_sqr_lo = { fill( 512, 0) } +(byte[512]) mul_sqr1_hi +(const byte[512]) mul_sqr1_hi#0 mul_sqr1_hi = { fill( 512, 0) } +(byte[512]) mul_sqr1_lo +(const byte[512]) mul_sqr1_lo#0 mul_sqr1_lo = { fill( 512, 0) } +(byte[512]) mul_sqr2_hi +(const byte[512]) mul_sqr2_hi#0 mul_sqr2_hi = { fill( 512, 0) } +(byte[512]) mul_sqr2_lo +(const byte[512]) mul_sqr2_lo#0 mul_sqr2_lo = { fill( 512, 0) } (void()) mul_tables_compare() (label) mul_tables_compare::@1 (label) mul_tables_compare::@2 (label) mul_tables_compare::@3 -(label) mul_tables_compare::@4 -(label) mul_tables_compare::@5 (label) mul_tables_compare::@6 (label) mul_tables_compare::@7 (label) mul_tables_compare::@8 (label) mul_tables_compare::@9 (label) mul_tables_compare::@return -(byte) mul_tables_compare::i -(byte) mul_tables_compare::i#1 reg byte x 16.5 -(byte) mul_tables_compare::i#10 reg byte x 12.222222222222221 +(byte*) mul_tables_compare::asm_sqr +(byte*) mul_tables_compare::asm_sqr#1 asm_sqr zp ZP_WORD:4 7.333333333333333 +(byte*) mul_tables_compare::asm_sqr#2 asm_sqr zp ZP_WORD:4 5.833333333333333 +(byte*) mul_tables_compare::kc_sqr +(byte*) mul_tables_compare::kc_sqr#1 kc_sqr zp ZP_WORD:2 16.5 +(byte*) mul_tables_compare::kc_sqr#2 kc_sqr zp ZP_WORD:2 3.1818181818181817 +(const string) mul_tables_compare::str str = (string) "mul table mismatch at @" +(const string) mul_tables_compare::str1 str1 = (string) " / @" +(void()) print_byte((byte) print_byte::b) +(byte~) print_byte::$0 reg byte y 4.0 +(byte~) print_byte::$2 reg byte a 4.0 +(label) print_byte::@1 +(label) print_byte::@return +(byte) print_byte::b +(byte) print_byte::b#0 reg byte x 4.0 +(byte) print_byte::b#1 reg byte x 4.0 +(byte) print_byte::b#2 reg byte x 2.0 +(byte[]) print_byte::hextab +(const byte[]) print_byte::hextab#0 hextab = { (byte) '0', (byte) '1', (byte) '2', (byte) '3', (byte) '4', (byte) '5', (byte) '6', (byte) '7', (byte) '8', (byte) '9', (byte) 'a', (byte) 'b', (byte) 'c', (byte) 'd', (byte) 'e', (byte) 'f' } +(void()) print_char((byte) print_char::ch) +(label) print_char::@return +(byte) print_char::ch +(byte) print_char::ch#0 reg byte a 4.0 +(byte) print_char::ch#1 reg byte a 4.0 +(byte) print_char::ch#2 reg byte a 6.0 +(void()) print_cls() +(label) print_cls::@1 +(label) print_cls::@return +(byte*) print_cls::sc +(byte*) print_cls::sc#1 sc zp ZP_WORD:6 16.5 +(byte*) print_cls::sc#2 sc zp ZP_WORD:6 16.5 +(void()) print_str((byte*) print_str::str) +(label) print_str::@1 +(label) print_str::@2 +(label) print_str::@return +(byte*) print_str::str +(byte*) print_str::str#0 str zp ZP_WORD:8 22.0 +(byte*) print_str::str#3 str zp ZP_WORD:8 11.5 +(byte*) print_str::str#5 str zp ZP_WORD:8 2.0 +(void()) print_word((word) print_word::w) +(label) print_word::@1 +(label) print_word::@return +(word) print_word::w +(word) print_word::w#0 w zp ZP_WORD:4 4.0 +(word) print_word::w#1 w zp ZP_WORD:4 4.0 +(word) print_word::w#2 w zp ZP_WORD:4 2.6666666666666665 -reg byte x [ mul_tables_compare::i#10 mul_tables_compare::i#1 ] +zp ZP_WORD:2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::kc_sqr#1 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_lo#1 ] +zp ZP_WORD:4 [ mul_tables_compare::asm_sqr#2 mul_tables_compare::asm_sqr#1 print_word::w#2 print_word::w#0 print_word::w#1 init_mul_tables::sqr1_hi#2 init_mul_tables::sqr1_hi#1 init_mul_tables::sqr2_hi#2 init_mul_tables::sqr2_hi#1 ] +reg byte x [ print_byte::b#2 print_byte::b#0 print_byte::b#1 ] +reg byte a [ print_char::ch#2 print_char::ch#0 print_char::ch#1 ] +zp ZP_WORD:6 [ char_cursor#44 char_cursor#27 char_cursor#39 char_cursor#19 char_cursor#17 char_cursor#10 char_cursor#1 print_cls::sc#2 print_cls::sc#1 init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] +zp ZP_WORD:8 [ print_str::str#3 print_str::str#5 print_str::str#0 ] reg byte x [ init_mul_tables::c#2 init_mul_tables::c#1 ] -zp ZP_WORD:2 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_lo#1 ] -zp ZP_WORD:4 [ init_mul_tables::sqr_hi#2 init_mul_tables::sqr_hi#1 ] -zp ZP_BYTE:6 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] -zp ZP_WORD:7 [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] +zp ZP_BYTE:10 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 init_mul_tables::dir#2 init_mul_tables::dir#3 ] +reg byte x [ init_mul_tables::x_255#2 init_mul_tables::x_255#1 ] +reg byte y [ print_byte::$0 ] +reg byte a [ print_byte::$2 ] reg byte a [ init_mul_tables::$2 ] reg byte a [ init_mul_tables::$5 ] reg byte a [ init_mul_tables::$6 ] @@ -1802,22 +4174,27 @@ FINAL ASSEMBLER .pc = $80d "Program" //SEG1 Global Constants & labels .const BGCOL = $d021 - mul_sqr_lo: .fill 512, 0 - mul_sqr_hi: .fill 512, 0 - asm_mul_sqr_lo: .fill 512, 0 - asm_mul_sqr_hi: .fill 512, 0 + .label char_cursor = 6 + mul_sqr1_lo: .fill 512, 0 + mul_sqr1_hi: .fill 512, 0 + mul_sqr2_lo: .fill 512, 0 + mul_sqr2_hi: .fill 512, 0 + asm_mul_sqr1_lo: .fill 512, 0 + asm_mul_sqr1_hi: .fill 512, 0 + asm_mul_sqr2_lo: .fill 512, 0 + asm_mul_sqr2_hi: .fill 512, 0 //SEG2 @begin -//SEG3 [1] phi from @begin to @4 [phi:@begin->@4] -//SEG4 @4 +//SEG3 [1] phi from @begin to @10 [phi:@begin->@10] +//SEG4 @10 //SEG5 [2] call main param-assignment [ ] ( ) -//SEG6 [4] phi from @4 to main [phi:@4->main] +//SEG6 [4] phi from @10 to main [phi:@10->main] jsr main -//SEG7 [3] phi from @4 to @end [phi:@4->@end] +//SEG7 [3] phi from @10 to @end [phi:@10->@end] //SEG8 @end //SEG9 main main: { //SEG10 [5] call init_mul_tables param-assignment [ ] ( main:2 [ ] ) - //SEG11 [26] phi from main to init_mul_tables [phi:main->init_mul_tables] + //SEG11 [66] phi from main to init_mul_tables [phi:main->init_mul_tables] jsr init_mul_tables //SEG12 [6] phi from main to main::@1 [phi:main->main::@1] //SEG13 main::@1 @@ -1833,68 +4210,260 @@ main: { } //SEG20 mul_tables_compare mul_tables_compare: { + .label asm_sqr = 4 + .label kc_sqr = 2 //SEG21 [11] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 5 [ ] ( main:2::mul_tables_compare:9 [ ] ) -- _deref_pbuc1=vbuc2 lda #5 sta BGCOL //SEG22 [12] phi from mul_tables_compare to mul_tables_compare::@1 [phi:mul_tables_compare->mul_tables_compare::@1] - //SEG23 [12] phi (byte) mul_tables_compare::i#10 = (byte/signed byte/word/signed word) 0 [phi:mul_tables_compare->mul_tables_compare::@1#0] -- vbuxx=vbuc1 - ldx #0 - //SEG24 [12] phi from mul_tables_compare::@5 to mul_tables_compare::@1 [phi:mul_tables_compare::@5->mul_tables_compare::@1] - //SEG25 [12] phi (byte) mul_tables_compare::i#10 = (byte) mul_tables_compare::i#1 [phi:mul_tables_compare::@5->mul_tables_compare::@1#0] -- register_copy - //SEG26 mul_tables_compare::@1 + //SEG23 [12] phi (byte*) mul_tables_compare::asm_sqr#2 = (const byte[512]) asm_mul_sqr1_lo#0 [phi:mul_tables_compare->mul_tables_compare::@1#0] -- pbuz1=pbuc1 + lda #asm_mul_sqr1_lo + sta asm_sqr+1 + //SEG24 [12] phi (byte*) mul_tables_compare::kc_sqr#2 = (const byte[512]) mul_sqr1_lo#0 [phi:mul_tables_compare->mul_tables_compare::@1#1] -- pbuz1=pbuc1 + lda #mul_sqr1_lo + sta kc_sqr+1 + //SEG25 [12] phi from mul_tables_compare::@2 to mul_tables_compare::@1 [phi:mul_tables_compare::@2->mul_tables_compare::@1] + //SEG26 [12] phi (byte*) mul_tables_compare::asm_sqr#2 = (byte*) mul_tables_compare::asm_sqr#1 [phi:mul_tables_compare::@2->mul_tables_compare::@1#0] -- register_copy + //SEG27 [12] phi (byte*) mul_tables_compare::kc_sqr#2 = (byte*) mul_tables_compare::kc_sqr#1 [phi:mul_tables_compare::@2->mul_tables_compare::@1#1] -- register_copy + //SEG28 mul_tables_compare::@1 b1: - //SEG27 [13] if(*((const byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- pbuc1_derefidx_vbuxx_eq_pbuc2_derefidx_vbuxx_then_la1 - lda mul_sqr_lo,x - cmp asm_mul_sqr_lo,x + //SEG29 [13] if(*((byte*) mul_tables_compare::kc_sqr#2)==*((byte*) mul_tables_compare::asm_sqr#2)) goto mul_tables_compare::@2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) -- _deref_pbuz1_eq__deref_pbuz2_then_la1 + ldy #0 + lda (kc_sqr),y + cmp (asm_sqr),y beq b2 - //SEG28 mul_tables_compare::@6 - //SEG29 [14] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- _deref_pbuc1=vbuc2 + //SEG30 mul_tables_compare::@3 + //SEG31 [14] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) -- _deref_pbuc1=vbuc2 lda #2 sta BGCOL - //SEG30 mul_tables_compare::@2 + //SEG32 [15] call print_cls param-assignment [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) + //SEG33 [54] phi from mul_tables_compare::@3 to print_cls [phi:mul_tables_compare::@3->print_cls] + jsr print_cls + //SEG34 [16] phi from mul_tables_compare::@3 to mul_tables_compare::@6 [phi:mul_tables_compare::@3->mul_tables_compare::@6] + //SEG35 mul_tables_compare::@6 + //SEG36 [17] call print_str param-assignment [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 ] ) + //SEG37 [47] phi from mul_tables_compare::@6 to print_str [phi:mul_tables_compare::@6->print_str] + //SEG38 [47] phi (byte*) char_cursor#44 = ((byte*))(word/signed word) 1024 [phi:mul_tables_compare::@6->print_str#0] -- pbuz1=pbuc1 + lda #<$400 + sta char_cursor + lda #>$400 + sta char_cursor+1 + //SEG39 [47] phi (byte*) print_str::str#5 = (const string) mul_tables_compare::str [phi:mul_tables_compare::@6->print_str#1] -- pbuz1=pbuc1 + lda #str + sta print_str.str+1 + jsr print_str + //SEG40 mul_tables_compare::@7 + //SEG41 [18] (word) print_word::w#0 ← ((word)) (byte*) mul_tables_compare::asm_sqr#2 [ mul_tables_compare::kc_sqr#2 print_word::w#0 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 print_word::w#0 char_cursor#19 ] ) -- vwuz1=_word_pbuz1 + //SEG42 [19] call print_word param-assignment [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] ) + //SEG43 [29] phi from mul_tables_compare::@7 to print_word [phi:mul_tables_compare::@7->print_word] + //SEG44 [29] phi (word) print_word::w#2 = (word) print_word::w#0 [phi:mul_tables_compare::@7->print_word#0] -- register_copy + jsr print_word + //SEG45 [20] phi from mul_tables_compare::@7 to mul_tables_compare::@8 [phi:mul_tables_compare::@7->mul_tables_compare::@8] + //SEG46 mul_tables_compare::@8 + //SEG47 [21] call print_str param-assignment [ mul_tables_compare::kc_sqr#2 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 char_cursor#19 ] ) + //SEG48 [47] phi from mul_tables_compare::@8 to print_str [phi:mul_tables_compare::@8->print_str] + //SEG49 [47] phi (byte*) char_cursor#44 = (byte*) char_cursor#10 [phi:mul_tables_compare::@8->print_str#0] -- register_copy + //SEG50 [47] phi (byte*) print_str::str#5 = (const string) mul_tables_compare::str1 [phi:mul_tables_compare::@8->print_str#1] -- pbuz1=pbuc1 + lda #str1 + sta print_str.str+1 + jsr print_str + //SEG51 mul_tables_compare::@9 + //SEG52 [22] (word) print_word::w#1 ← ((word)) (byte*) mul_tables_compare::kc_sqr#2 [ print_word::w#1 char_cursor#19 ] ( main:2::mul_tables_compare:9 [ print_word::w#1 char_cursor#19 ] ) -- vwuz1=_word_pbuz2 + lda kc_sqr + sta print_word.w + lda kc_sqr+1 + sta print_word.w+1 + //SEG53 [23] call print_word param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9 [ char_cursor#10 ] ) + //SEG54 [29] phi from mul_tables_compare::@9 to print_word [phi:mul_tables_compare::@9->print_word] + //SEG55 [29] phi (word) print_word::w#2 = (word) print_word::w#1 [phi:mul_tables_compare::@9->print_word#0] -- register_copy + jsr print_word + //SEG56 [24] phi from mul_tables_compare::@9 to mul_tables_compare::@return [phi:mul_tables_compare::@9->mul_tables_compare::@return] + //SEG57 [24] phi (byte*) char_cursor#17 = (byte*) char_cursor#10 [phi:mul_tables_compare::@9->mul_tables_compare::@return#0] -- register_copy + //SEG58 mul_tables_compare::@return + breturn: + //SEG59 [25] return [ ] ( main:2::mul_tables_compare:9 [ ] ) + rts + //SEG60 mul_tables_compare::@2 b2: - //SEG31 [15] if(*((const byte[512]) mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@3 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- pbuc1_derefidx_vbuxx_eq_pbuc2_derefidx_vbuxx_then_la1 - lda mul_sqr_hi+$100,x - cmp asm_mul_sqr_hi+$100,x - beq b3 - //SEG32 mul_tables_compare::@7 - //SEG33 [16] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- _deref_pbuc1=vbuc2 - lda #2 - sta BGCOL - //SEG34 mul_tables_compare::@3 - b3: - //SEG35 [17] if(*((const byte[512]) mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_lo#0 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@4 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- pbuc1_derefidx_vbuxx_eq_pbuc2_derefidx_vbuxx_then_la1 - lda mul_sqr_lo,x - cmp asm_mul_sqr_lo,x - beq b4 - //SEG36 mul_tables_compare::@8 - //SEG37 [18] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- _deref_pbuc1=vbuc2 - lda #2 - sta BGCOL - //SEG38 mul_tables_compare::@4 - b4: - //SEG39 [19] if(*((const byte[512]) mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)==*((const byte[512]) asm_mul_sqr_hi#0+(word/signed word) 256 + (byte) mul_tables_compare::i#10)) goto mul_tables_compare::@5 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- pbuc1_derefidx_vbuxx_eq_pbuc2_derefidx_vbuxx_then_la1 - lda mul_sqr_hi+$100,x - cmp asm_mul_sqr_hi+$100,x - beq b5 - //SEG40 mul_tables_compare::@9 - //SEG41 [20] *((const byte*) BGCOL#0) ← (byte/signed byte/word/signed word) 2 [ mul_tables_compare::i#10 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#10 ] ) -- _deref_pbuc1=vbuc2 - lda #2 - sta BGCOL - //SEG42 mul_tables_compare::@5 - b5: - //SEG43 [21] (byte) mul_tables_compare::i#1 ← ++ (byte) mul_tables_compare::i#10 [ mul_tables_compare::i#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#1 ] ) -- vbuxx=_inc_vbuxx - inx - //SEG44 [22] if((byte) mul_tables_compare::i#1!=(byte/signed byte/word/signed word) 0) goto mul_tables_compare::@1 [ mul_tables_compare::i#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::i#1 ] ) -- vbuxx_neq_0_then_la1 - cpx #0 - bne b1 - //SEG45 mul_tables_compare::@return - //SEG46 [23] return [ ] ( main:2::mul_tables_compare:9 [ ] ) + //SEG61 [26] (byte*) mul_tables_compare::asm_sqr#1 ← ++ (byte*) mul_tables_compare::asm_sqr#2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#1 ] ) -- pbuz1=_inc_pbuz1 + inc asm_sqr + bne !+ + inc asm_sqr+1 + !: + //SEG62 [27] (byte*) mul_tables_compare::kc_sqr#1 ← ++ (byte*) mul_tables_compare::kc_sqr#2 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ) -- pbuz1=_inc_pbuz1 + inc kc_sqr + bne !+ + inc kc_sqr+1 + !: + //SEG63 [28] if((byte*) mul_tables_compare::kc_sqr#1<(const byte[512]) mul_sqr1_lo#0+(word/signed word) 512*(byte/signed byte/word/signed word) 4) goto mul_tables_compare::@1 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ( main:2::mul_tables_compare:9 [ mul_tables_compare::kc_sqr#1 mul_tables_compare::asm_sqr#1 ] ) -- pbuz1_lt_pbuc1_then_la1 + lda kc_sqr+1 + cmp #>mul_sqr1_lo+$200*4 + bcc b1 + bne !+ + lda kc_sqr + cmp #mul_tables_compare::@return] + //SEG65 [24] phi (byte*) char_cursor#17 = ((byte*))(word/signed word) 1024 [phi:mul_tables_compare::@2->mul_tables_compare::@return#0] -- pbuz1=pbuc1 + lda #<$400 + sta char_cursor + lda #>$400 + sta char_cursor+1 + jmp breturn + str: .text "mul table mismatch at @" + str1: .text " / @" +} +//SEG66 print_word +print_word: { + .label w = 4 + //SEG67 [30] (byte) print_byte::b#0 ← > (word) print_word::w#2 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#0 char_cursor#19 ] main:2::mul_tables_compare:9::print_word:23 [ print_word::w#2 print_byte::b#0 char_cursor#19 ] ) -- vbuxx=_hi_vwuz1 + lda w+1 + tax + //SEG68 [31] call print_byte param-assignment [ char_cursor#10 print_word::w#2 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_word::w#2 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 print_word::w#2 ] ) + //SEG69 [35] phi from print_word to print_byte [phi:print_word->print_byte] + //SEG70 [35] phi (byte*) char_cursor#39 = (byte*) char_cursor#19 [phi:print_word->print_byte#0] -- register_copy + //SEG71 [35] phi (byte) print_byte::b#2 = (byte) print_byte::b#0 [phi:print_word->print_byte#1] -- register_copy + jsr print_byte + //SEG72 print_word::@1 + //SEG73 [32] (byte) print_byte::b#1 ← < (word) print_word::w#2 [ char_cursor#10 print_byte::b#1 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::b#1 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 print_byte::b#1 ] ) -- vbuxx=_lo_vwuz1 + lda w + tax + //SEG74 [33] call print_byte param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 ] ) + //SEG75 [35] phi from print_word::@1 to print_byte [phi:print_word::@1->print_byte] + //SEG76 [35] phi (byte*) char_cursor#39 = (byte*) char_cursor#10 [phi:print_word::@1->print_byte#0] -- register_copy + //SEG77 [35] phi (byte) print_byte::b#2 = (byte) print_byte::b#1 [phi:print_word::@1->print_byte#1] -- register_copy + jsr print_byte + //SEG78 print_word::@return + //SEG79 [34] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23 [ char_cursor#10 ] ) rts } -//SEG47 init_mul_tables_asm +//SEG80 print_byte +print_byte: { + //SEG81 [36] (byte~) print_byte::$0 ← (byte) print_byte::b#2 >> (byte/signed byte/word/signed word) 4 [ print_byte::b#2 char_cursor#39 print_byte::$0 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 print_byte::$0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 print_byte::$0 ] ) -- vbuyy=vbuxx_ror_4 + txa + lsr + lsr + lsr + lsr + tay + //SEG82 [37] (byte) print_char::ch#0 ← *((const byte[]) print_byte::hextab#0 + (byte~) print_byte::$0) [ print_byte::b#2 char_cursor#39 print_char::ch#0 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#39 print_char::ch#0 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ print_byte::b#2 char_cursor#39 print_char::ch#0 ] ) -- vbuaa=pbuc1_derefidx_vbuyy + lda hextab,y + //SEG83 [38] call print_char param-assignment [ char_cursor#10 print_byte::b#2 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::b#2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_byte::b#2 ] ) + //SEG84 [43] phi from print_byte to print_char [phi:print_byte->print_char] + //SEG85 [43] phi (byte*) char_cursor#27 = (byte*) char_cursor#39 [phi:print_byte->print_char#0] -- register_copy + //SEG86 [43] phi (byte) print_char::ch#2 = (byte) print_char::ch#0 [phi:print_byte->print_char#1] -- register_copy + jsr print_char + //SEG87 print_byte::@1 + //SEG88 [39] (byte~) print_byte::$2 ← (byte) print_byte::b#2 & (byte/signed byte/word/signed word) 15 [ char_cursor#10 print_byte::$2 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_byte::$2 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_byte::$2 ] ) -- vbuaa=vbuxx_band_vbuc1 + txa + and #$f + //SEG89 [40] (byte) print_char::ch#1 ← *((const byte[]) print_byte::hextab#0 + (byte~) print_byte::$2) [ char_cursor#10 print_char::ch#1 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 print_char::ch#1 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 print_char::ch#1 ] ) -- vbuaa=pbuc1_derefidx_vbuaa + tax + lda hextab,x + //SEG90 [41] call print_char param-assignment [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 ] ) + //SEG91 [43] phi from print_byte::@1 to print_char [phi:print_byte::@1->print_char] + //SEG92 [43] phi (byte*) char_cursor#27 = (byte*) char_cursor#10 [phi:print_byte::@1->print_char#0] -- register_copy + //SEG93 [43] phi (byte) print_char::ch#2 = (byte) print_char::ch#1 [phi:print_byte::@1->print_char#1] -- register_copy + jsr print_char + //SEG94 print_byte::@return + //SEG95 [42] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33 [ char_cursor#10 ] ) + rts + hextab: .byte '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f' +} +//SEG96 print_char +print_char: { + //SEG97 [44] *((byte*) char_cursor#27) ← (byte) print_char::ch#2 [ char_cursor#27 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#27 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#27 ] ) -- _deref_pbuz1=vbuaa + ldy #0 + sta (char_cursor),y + //SEG98 [45] (byte*) char_cursor#10 ← ++ (byte*) char_cursor#27 [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#10 ] ) -- pbuz1=_inc_pbuz1 + inc char_cursor + bne !+ + inc char_cursor+1 + !: + //SEG99 print_char::@return + //SEG100 [46] return [ char_cursor#10 ] ( main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:38 [ mul_tables_compare::kc_sqr#2 print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:38 [ print_word::w#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:38 [ mul_tables_compare::kc_sqr#2 print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:38 [ print_byte::b#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:31::print_char:41 [ mul_tables_compare::kc_sqr#2 print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:31::print_char:41 [ print_word::w#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:19::print_byte:33::print_char:41 [ mul_tables_compare::kc_sqr#2 char_cursor#10 ] main:2::mul_tables_compare:9::print_word:23::print_byte:33::print_char:41 [ char_cursor#10 ] ) + rts +} +//SEG101 print_str +print_str: { + .label str = 8 + //SEG102 [48] phi from print_str print_str::@2 to print_str::@1 [phi:print_str/print_str::@2->print_str::@1] + //SEG103 [48] phi (byte*) char_cursor#19 = (byte*) char_cursor#44 [phi:print_str/print_str::@2->print_str::@1#0] -- register_copy + //SEG104 [48] phi (byte*) print_str::str#3 = (byte*) print_str::str#5 [phi:print_str/print_str::@2->print_str::@1#1] -- register_copy + //SEG105 print_str::@1 + b1: + //SEG106 [49] if(*((byte*) print_str::str#3)!=(byte) '@') goto print_str::@2 [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) -- _deref_pbuz1_neq_vbuc1_then_la1 + ldy #0 + lda (str),y + cmp #'@' + bne b2 + //SEG107 print_str::@return + //SEG108 [50] return [ char_cursor#19 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 ] ) + rts + //SEG109 print_str::@2 + b2: + //SEG110 [51] *((byte*) char_cursor#19) ← *((byte*) print_str::str#3) [ char_cursor#19 print_str::str#3 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 char_cursor#19 print_str::str#3 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 char_cursor#19 print_str::str#3 ] ) -- _deref_pbuz1=_deref_pbuz2 + ldy #0 + lda (str),y + sta (char_cursor),y + //SEG111 [52] (byte*) char_cursor#1 ← ++ (byte*) char_cursor#19 [ print_str::str#3 char_cursor#1 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#3 char_cursor#1 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#3 char_cursor#1 ] ) -- pbuz1=_inc_pbuz1 + inc char_cursor + bne !+ + inc char_cursor+1 + !: + //SEG112 [53] (byte*) print_str::str#0 ← ++ (byte*) print_str::str#3 [ print_str::str#0 char_cursor#1 ] ( main:2::mul_tables_compare:9::print_str:17 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_str::str#0 char_cursor#1 ] main:2::mul_tables_compare:9::print_str:21 [ mul_tables_compare::kc_sqr#2 print_str::str#0 char_cursor#1 ] ) -- pbuz1=_inc_pbuz1 + inc str + bne !+ + inc str+1 + !: + jmp b1 +} +//SEG113 print_cls +print_cls: { + .label sc = 6 + //SEG114 [55] phi from print_cls to print_cls::@1 [phi:print_cls->print_cls::@1] + //SEG115 [55] phi (byte*) print_cls::sc#2 = ((byte*))(word/signed word) 1024 [phi:print_cls->print_cls::@1#0] -- pbuz1=pbuc1 + lda #<$400 + sta sc + lda #>$400 + sta sc+1 + //SEG116 [55] phi from print_cls::@1 to print_cls::@1 [phi:print_cls::@1->print_cls::@1] + //SEG117 [55] phi (byte*) print_cls::sc#2 = (byte*) print_cls::sc#1 [phi:print_cls::@1->print_cls::@1#0] -- register_copy + //SEG118 print_cls::@1 + b1: + //SEG119 [56] *((byte*) print_cls::sc#2) ← (byte) ' ' [ print_cls::sc#2 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#2 ] ) -- _deref_pbuz1=vbuc1 + ldy #0 + lda #' ' + sta (sc),y + //SEG120 [57] (byte*) print_cls::sc#1 ← ++ (byte*) print_cls::sc#2 [ print_cls::sc#1 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#1 ] ) -- pbuz1=_inc_pbuz1 + inc sc + bne !+ + inc sc+1 + !: + //SEG121 [58] if((byte*) print_cls::sc#1!=(word/signed word) 1024+(word/signed word) 1000) goto print_cls::@1 [ print_cls::sc#1 ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 print_cls::sc#1 ] ) -- pbuz1_neq_vwuc1_then_la1 + lda sc+1 + cmp #>$400+$3e8 + bne b1 + lda sc + cmp #<$400+$3e8 + bne b1 + //SEG122 print_cls::@return + //SEG123 [59] return [ ] ( main:2::mul_tables_compare:9::print_cls:15 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::asm_sqr#2 ] ) + rts +} +//SEG124 init_mul_tables_asm init_mul_tables_asm: { - //SEG48 asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr_lo,xbnelb1incml0+2incml1+2clcinybnelb1 } + .const mem = $ff + //SEG125 asm { ldx#$00txa.byte$c9lb1:tyaadc#$00ml1:staasm_mul_sqr1_hi,xtaycmp#$40txarorml9:adc#$00staml9+1inxml0:staasm_mul_sqr1_lo,xbnelb1incml0+2incml1+2clcinybnelb1ldx#$00ldy#$ff!:ldaasm_mul_sqr1_hi+1,xstaasm_mul_sqr2_hi+$100,xldaasm_mul_sqr1_hi,xstaasm_mul_sqr2_hi,yldaasm_mul_sqr1_lo+1,xstaasm_mul_sqr2_lo+$100,xldaasm_mul_sqr1_lo,xstaasm_mul_sqr2_lo,ydeyinxbne!- } ldx #0 txa .byte $c9 @@ -1902,7 +4471,7 @@ init_mul_tables_asm: { tya adc #0 ml1: - sta asm_mul_sqr_hi,x + sta asm_mul_sqr1_hi,x tay cmp #$40 txa @@ -1912,87 +4481,116 @@ init_mul_tables_asm: { sta ml9+1 inx ml0: - sta asm_mul_sqr_lo,x + sta asm_mul_sqr1_lo,x bne lb1 inc ml0+2 inc ml1+2 clc iny bne lb1 - //SEG49 init_mul_tables_asm::@return - //SEG50 [25] return [ ] ( main:2::init_mul_tables_asm:7 [ ] ) + ldx #0 + ldy #$ff + !: + lda asm_mul_sqr1_hi+1,x + sta asm_mul_sqr2_hi+$100,x + lda asm_mul_sqr1_hi,x + sta asm_mul_sqr2_hi,y + lda asm_mul_sqr1_lo+1,x + sta asm_mul_sqr2_lo+$100,x + lda asm_mul_sqr1_lo,x + sta asm_mul_sqr2_lo,y + dey + inx + bne !- + //SEG126 [61] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) -- _deref_pbuc1=_deref_pbuc2 + lda asm_mul_sqr1_lo + sta mem + //SEG127 [62] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr1_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) -- _deref_pbuc1=_deref_pbuc2 + lda asm_mul_sqr1_hi + sta mem + //SEG128 [63] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_lo#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) -- _deref_pbuc1=_deref_pbuc2 + lda asm_mul_sqr2_lo + sta mem + //SEG129 [64] *((const byte*) init_mul_tables_asm::mem#0) ← *((const byte[512]) asm_mul_sqr2_hi#0) [ ] ( main:2::init_mul_tables_asm:7 [ ] ) -- _deref_pbuc1=_deref_pbuc2 + lda asm_mul_sqr2_hi + sta mem + //SEG130 init_mul_tables_asm::@return + //SEG131 [65] return [ ] ( main:2::init_mul_tables_asm:7 [ ] ) rts } -//SEG51 init_mul_tables +//SEG132 init_mul_tables init_mul_tables: { - .label sqr_hi = 4 - .label sqr = 7 - .label sqr_lo = 2 - .label x_2 = 6 - //SEG52 [27] phi from init_mul_tables to init_mul_tables::@1 [phi:init_mul_tables->init_mul_tables::@1] - //SEG53 [27] phi (byte) init_mul_tables::x_2#3 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#0] -- vbuz1=vbuc1 + .label sqr1_hi = 4 + .label sqr = 6 + .label sqr1_lo = 2 + .label x_2 = $a + .label sqr2_hi = 4 + .label sqr2_lo = 2 + .label dir = $a + //SEG133 [67] phi from init_mul_tables to init_mul_tables::@1 [phi:init_mul_tables->init_mul_tables::@1] + //SEG134 [67] phi (byte) init_mul_tables::x_2#3 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#0] -- vbuz1=vbuc1 lda #0 sta x_2 - //SEG54 [27] phi (byte*) init_mul_tables::sqr_hi#2 = (const byte[512]) mul_sqr_hi#0+(byte/signed byte/word/signed word) 1 [phi:init_mul_tables->init_mul_tables::@1#1] -- pbuz1=pbuc1 - lda #mul_sqr_hi+1 - sta sqr_hi+1 - //SEG55 [27] phi (byte*) init_mul_tables::sqr_lo#2 = (const byte[512]) mul_sqr_lo#0+(byte/signed byte/word/signed word) 1 [phi:init_mul_tables->init_mul_tables::@1#2] -- pbuz1=pbuc1 - lda #mul_sqr_lo+1 - sta sqr_lo+1 - //SEG56 [27] phi (word) init_mul_tables::sqr#4 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#3] -- vwuz1=vbuc1 + //SEG135 [67] phi (byte*) init_mul_tables::sqr1_hi#2 = (const byte[512]) mul_sqr1_hi#0+(byte/signed byte/word/signed word) 1 [phi:init_mul_tables->init_mul_tables::@1#1] -- pbuz1=pbuc1 + lda #mul_sqr1_hi+1 + sta sqr1_hi+1 + //SEG136 [67] phi (byte*) init_mul_tables::sqr1_lo#2 = (const byte[512]) mul_sqr1_lo#0+(byte/signed byte/word/signed word) 1 [phi:init_mul_tables->init_mul_tables::@1#2] -- pbuz1=pbuc1 + lda #mul_sqr1_lo+1 + sta sqr1_lo+1 + //SEG137 [67] phi (word) init_mul_tables::sqr#4 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#3] -- vwuz1=vbuc1 lda #0 sta sqr sta sqr+1 - //SEG57 [27] phi (byte) init_mul_tables::c#2 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#4] -- vbuxx=vbuc1 + //SEG138 [67] phi (byte) init_mul_tables::c#2 = (byte/signed byte/word/signed word) 0 [phi:init_mul_tables->init_mul_tables::@1#4] -- vbuxx=vbuc1 tax - //SEG58 [27] phi from init_mul_tables::@2 to init_mul_tables::@1 [phi:init_mul_tables::@2->init_mul_tables::@1] - //SEG59 [27] phi (byte) init_mul_tables::x_2#3 = (byte) init_mul_tables::x_2#2 [phi:init_mul_tables::@2->init_mul_tables::@1#0] -- register_copy - //SEG60 [27] phi (byte*) init_mul_tables::sqr_hi#2 = (byte*) init_mul_tables::sqr_hi#1 [phi:init_mul_tables::@2->init_mul_tables::@1#1] -- register_copy - //SEG61 [27] phi (byte*) init_mul_tables::sqr_lo#2 = (byte*) init_mul_tables::sqr_lo#1 [phi:init_mul_tables::@2->init_mul_tables::@1#2] -- register_copy - //SEG62 [27] phi (word) init_mul_tables::sqr#4 = (word) init_mul_tables::sqr#1 [phi:init_mul_tables::@2->init_mul_tables::@1#3] -- register_copy - //SEG63 [27] phi (byte) init_mul_tables::c#2 = (byte) init_mul_tables::c#1 [phi:init_mul_tables::@2->init_mul_tables::@1#4] -- register_copy - //SEG64 init_mul_tables::@1 + //SEG139 [67] phi from init_mul_tables::@2 to init_mul_tables::@1 [phi:init_mul_tables::@2->init_mul_tables::@1] + //SEG140 [67] phi (byte) init_mul_tables::x_2#3 = (byte) init_mul_tables::x_2#2 [phi:init_mul_tables::@2->init_mul_tables::@1#0] -- register_copy + //SEG141 [67] phi (byte*) init_mul_tables::sqr1_hi#2 = (byte*) init_mul_tables::sqr1_hi#1 [phi:init_mul_tables::@2->init_mul_tables::@1#1] -- register_copy + //SEG142 [67] phi (byte*) init_mul_tables::sqr1_lo#2 = (byte*) init_mul_tables::sqr1_lo#1 [phi:init_mul_tables::@2->init_mul_tables::@1#2] -- register_copy + //SEG143 [67] phi (word) init_mul_tables::sqr#4 = (word) init_mul_tables::sqr#1 [phi:init_mul_tables::@2->init_mul_tables::@1#3] -- register_copy + //SEG144 [67] phi (byte) init_mul_tables::c#2 = (byte) init_mul_tables::c#1 [phi:init_mul_tables::@2->init_mul_tables::@1#4] -- register_copy + //SEG145 init_mul_tables::@1 b1: - //SEG65 [28] (byte) init_mul_tables::c#1 ← ++ (byte) init_mul_tables::c#2 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) -- vbuxx=_inc_vbuxx + //SEG146 [68] (byte) init_mul_tables::c#1 ← ++ (byte) init_mul_tables::c#2 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) -- vbuxx=_inc_vbuxx inx - //SEG66 [29] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) -- vbuaa=vbuxx_band_vbuc1 + //SEG147 [69] (byte~) init_mul_tables::$2 ← (byte) init_mul_tables::c#1 & (byte/signed byte/word/signed word) 1 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 init_mul_tables::$2 ] ) -- vbuaa=vbuxx_band_vbuc1 txa and #1 - //SEG67 [30] if((byte~) init_mul_tables::$2!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@2 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) -- vbuaa_neq_0_then_la1 + //SEG148 [70] if((byte~) init_mul_tables::$2!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@2 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::x_2#3 init_mul_tables::c#1 ] ) -- vbuaa_neq_0_then_la1 cmp #0 bne b2 - //SEG68 init_mul_tables::@3 - //SEG69 [31] (byte) init_mul_tables::x_2#1 ← ++ (byte) init_mul_tables::x_2#3 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ) -- vbuz1=_inc_vbuz1 + //SEG149 init_mul_tables::@5 + //SEG150 [71] (byte) init_mul_tables::x_2#1 ← ++ (byte) init_mul_tables::x_2#3 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr#4 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 ] ) -- vbuz1=_inc_vbuz1 inc x_2 - //SEG70 [32] (word) init_mul_tables::sqr#2 ← ++ (word) init_mul_tables::sqr#4 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ) -- vwuz1=_inc_vwuz1 + //SEG151 [72] (word) init_mul_tables::sqr#2 ← ++ (word) init_mul_tables::sqr#4 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#1 init_mul_tables::sqr#2 ] ) -- vwuz1=_inc_vwuz1 inc sqr bne !+ inc sqr+1 !: - //SEG71 [33] phi from init_mul_tables::@1 init_mul_tables::@3 to init_mul_tables::@2 [phi:init_mul_tables::@1/init_mul_tables::@3->init_mul_tables::@2] - //SEG72 [33] phi (byte) init_mul_tables::x_2#2 = (byte) init_mul_tables::x_2#3 [phi:init_mul_tables::@1/init_mul_tables::@3->init_mul_tables::@2#0] -- register_copy - //SEG73 [33] phi (word) init_mul_tables::sqr#3 = (word) init_mul_tables::sqr#4 [phi:init_mul_tables::@1/init_mul_tables::@3->init_mul_tables::@2#1] -- register_copy - //SEG74 init_mul_tables::@2 + //SEG152 [73] phi from init_mul_tables::@1 init_mul_tables::@5 to init_mul_tables::@2 [phi:init_mul_tables::@1/init_mul_tables::@5->init_mul_tables::@2] + //SEG153 [73] phi (byte) init_mul_tables::x_2#2 = (byte) init_mul_tables::x_2#3 [phi:init_mul_tables::@1/init_mul_tables::@5->init_mul_tables::@2#0] -- register_copy + //SEG154 [73] phi (word) init_mul_tables::sqr#3 = (word) init_mul_tables::sqr#4 [phi:init_mul_tables::@1/init_mul_tables::@5->init_mul_tables::@2#1] -- register_copy + //SEG155 init_mul_tables::@2 b2: - //SEG75 [34] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) -- vbuaa=_lo_vwuz1 + //SEG156 [74] (byte~) init_mul_tables::$5 ← < (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$5 ] ) -- vbuaa=_lo_vwuz1 lda sqr - //SEG76 [35] *((byte*) init_mul_tables::sqr_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- _deref_pbuz1=vbuaa + //SEG157 [75] *((byte*) init_mul_tables::sqr1_lo#2) ← (byte~) init_mul_tables::$5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- _deref_pbuz1=vbuaa ldy #0 - sta (sqr_lo),y - //SEG77 [36] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) -- vbuaa=_hi_vwuz1 + sta (sqr1_lo),y + //SEG158 [76] (byte~) init_mul_tables::$6 ← > (word) init_mul_tables::sqr#3 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 init_mul_tables::$6 ] ) -- vbuaa=_hi_vwuz1 lda sqr+1 - //SEG78 [37] *((byte*) init_mul_tables::sqr_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- _deref_pbuz1=vbuaa - sta (sqr_hi),y - //SEG79 [38] (byte*) init_mul_tables::sqr_hi#1 ← ++ (byte*) init_mul_tables::sqr_hi#2 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- pbuz1=_inc_pbuz1 - inc sqr_hi + //SEG159 [77] *((byte*) init_mul_tables::sqr1_hi#2) ← (byte~) init_mul_tables::$6 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_hi#2 init_mul_tables::c#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- _deref_pbuz1=vbuaa + sta (sqr1_hi),y + //SEG160 [78] (byte*) init_mul_tables::sqr1_hi#1 ← ++ (byte*) init_mul_tables::sqr1_hi#2 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 init_mul_tables::sqr#3 ] ) -- pbuz1=_inc_pbuz1 + inc sqr1_hi bne !+ - inc sqr_hi+1 + inc sqr1_hi+1 !: - //SEG80 [39] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) -- vwuz1=vwuz1_plus_vbuz2 + //SEG161 [79] (word) init_mul_tables::sqr#1 ← (word) init_mul_tables::sqr#3 + (byte) init_mul_tables::x_2#2 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr1_lo#2 init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) -- vwuz1=vwuz1_plus_vbuz2 lda x_2 clc adc sqr @@ -2000,20 +4598,92 @@ init_mul_tables: { bcc !+ inc sqr+1 !: - //SEG81 [40] (byte*) init_mul_tables::sqr_lo#1 ← ++ (byte*) init_mul_tables::sqr_lo#2 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) -- pbuz1=_inc_pbuz1 - inc sqr_lo + //SEG162 [80] (byte*) init_mul_tables::sqr1_lo#1 ← ++ (byte*) init_mul_tables::sqr1_lo#2 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) -- pbuz1=_inc_pbuz1 + inc sqr1_lo bne !+ - inc sqr_lo+1 + inc sqr1_lo+1 !: - //SEG82 [41] if((byte*) init_mul_tables::sqr_lo#1!=(const byte[512]) mul_sqr_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr_lo#1 init_mul_tables::sqr_hi#1 init_mul_tables::x_2#2 ] ) -- pbuz1_neq_pbuc1_then_la1 - lda sqr_lo+1 - cmp #>mul_sqr_lo+$200 + //SEG163 [81] if((byte*) init_mul_tables::sqr1_lo#1!=(const byte[512]) mul_sqr1_lo#0+(word/signed word) 512) goto init_mul_tables::@1 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::c#1 init_mul_tables::sqr#1 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr1_hi#1 init_mul_tables::x_2#2 ] ) -- pbuz1_neq_pbuc1_then_la1 + lda sqr1_lo+1 + cmp #>mul_sqr1_lo+$200 bne b1 - lda sqr_lo - cmp #init_mul_tables::@3] + //SEG165 [82] phi (byte) init_mul_tables::dir#2 = (byte/word/signed word) 255 [phi:init_mul_tables::@2->init_mul_tables::@3#0] -- vbuz1=vbuc1 + lda #$ff + sta dir + //SEG166 [82] phi (byte*) init_mul_tables::sqr2_hi#2 = (const byte[512]) mul_sqr2_hi#0 [phi:init_mul_tables::@2->init_mul_tables::@3#1] -- pbuz1=pbuc1 + lda #mul_sqr2_hi + sta sqr2_hi+1 + //SEG167 [82] phi (byte*) init_mul_tables::sqr2_lo#2 = (const byte[512]) mul_sqr2_lo#0 [phi:init_mul_tables::@2->init_mul_tables::@3#2] -- pbuz1=pbuc1 + lda #mul_sqr2_lo + sta sqr2_lo+1 + //SEG168 [82] phi (byte) init_mul_tables::x_255#2 = ((byte))-(byte/signed byte/word/signed word) 1 [phi:init_mul_tables::@2->init_mul_tables::@3#3] -- vbuxx=vbuc1 + ldx #-1 + //SEG169 [82] phi from init_mul_tables::@4 to init_mul_tables::@3 [phi:init_mul_tables::@4->init_mul_tables::@3] + //SEG170 [82] phi (byte) init_mul_tables::dir#2 = (byte) init_mul_tables::dir#3 [phi:init_mul_tables::@4->init_mul_tables::@3#0] -- register_copy + //SEG171 [82] phi (byte*) init_mul_tables::sqr2_hi#2 = (byte*) init_mul_tables::sqr2_hi#1 [phi:init_mul_tables::@4->init_mul_tables::@3#1] -- register_copy + //SEG172 [82] phi (byte*) init_mul_tables::sqr2_lo#2 = (byte*) init_mul_tables::sqr2_lo#1 [phi:init_mul_tables::@4->init_mul_tables::@3#2] -- register_copy + //SEG173 [82] phi (byte) init_mul_tables::x_255#2 = (byte) init_mul_tables::x_255#1 [phi:init_mul_tables::@4->init_mul_tables::@3#3] -- register_copy + //SEG174 init_mul_tables::@3 + b3: + //SEG175 [83] *((byte*) init_mul_tables::sqr2_lo#2) ← *((const byte[512]) mul_sqr1_lo#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) -- _deref_pbuz1=pbuc1_derefidx_vbuxx + lda mul_sqr1_lo,x + ldy #0 + sta (sqr2_lo),y + //SEG176 [84] *((byte*) init_mul_tables::sqr2_hi#2) ← *((const byte[512]) mul_sqr1_hi#0 + (byte) init_mul_tables::x_255#2) [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_hi#2 init_mul_tables::dir#2 ] ) -- _deref_pbuz1=pbuc1_derefidx_vbuxx + lda mul_sqr1_hi,x + sta (sqr2_hi),y + //SEG177 [85] (byte*) init_mul_tables::sqr2_hi#1 ← ++ (byte*) init_mul_tables::sqr2_hi#2 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#2 init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::sqr2_hi#1 ] ) -- pbuz1=_inc_pbuz1 + inc sqr2_hi + bne !+ + inc sqr2_hi+1 + !: + //SEG178 [86] (byte) init_mul_tables::x_255#1 ← (byte) init_mul_tables::x_255#2 + (byte) init_mul_tables::dir#2 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) -- vbuxx=vbuxx_plus_vbuz1 + txa + clc + adc dir + tax + //SEG179 [87] if((byte) init_mul_tables::x_255#1!=(byte/signed byte/word/signed word) 0) goto init_mul_tables::@12 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ( main:2::init_mul_tables:5 [ init_mul_tables::sqr2_lo#2 init_mul_tables::dir#2 init_mul_tables::x_255#1 init_mul_tables::sqr2_hi#1 ] ) -- vbuxx_neq_0_then_la1 + cpx #0 + bne b4 + //SEG180 [88] phi from init_mul_tables::@3 to init_mul_tables::@4 [phi:init_mul_tables::@3->init_mul_tables::@4] + //SEG181 [88] phi (byte) init_mul_tables::dir#3 = (byte/signed byte/word/signed word) 1 [phi:init_mul_tables::@3->init_mul_tables::@4#0] -- vbuz1=vbuc1 + lda #1 + sta dir + //SEG182 init_mul_tables::@4 + b4: + //SEG183 [89] (byte*) init_mul_tables::sqr2_lo#1 ← ++ (byte*) init_mul_tables::sqr2_lo#2 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) -- pbuz1=_inc_pbuz1 + inc sqr2_lo + bne !+ + inc sqr2_lo+1 + !: + //SEG184 [90] if((byte*) init_mul_tables::sqr2_lo#1!=(const byte[512]) mul_sqr2_lo#0+(word/signed word) 511) goto init_mul_tables::@3 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ( main:2::init_mul_tables:5 [ init_mul_tables::x_255#1 init_mul_tables::sqr2_lo#1 init_mul_tables::sqr2_hi#1 init_mul_tables::dir#3 ] ) -- pbuz1_neq_pbuc1_then_la1 + lda sqr2_lo+1 + cmp #>mul_sqr2_lo+$1ff + bne b3 + lda sqr2_lo + cmp #init_mul_tables::@12] + //SEG191 init_mul_tables::@12 + //SEG192 [88] phi from init_mul_tables::@12 to init_mul_tables::@4 [phi:init_mul_tables::@12->init_mul_tables::@4] + //SEG193 [88] phi (byte) init_mul_tables::dir#3 = (byte) init_mul_tables::dir#2 [phi:init_mul_tables::@12->init_mul_tables::@4#0] -- register_copy } diff --git a/src/test/java/dk/camelot64/kickc/test/ref/multiply.sym b/src/test/java/dk/camelot64/kickc/test/ref/multiply.sym index 0bb98fdee..b9739290a 100644 --- a/src/test/java/dk/camelot64/kickc/test/ref/multiply.sym +++ b/src/test/java/dk/camelot64/kickc/test/ref/multiply.sym @@ -1,69 +1,150 @@ -(label) @4 +(label) @10 (label) @begin (label) @end (byte*) BGCOL (const byte*) BGCOL#0 BGCOL = ((byte*))(word) 53281 -(byte[512]) asm_mul_sqr_hi -(const byte[512]) asm_mul_sqr_hi#0 asm_mul_sqr_hi = { fill( 512, 0) } -(byte[512]) asm_mul_sqr_lo -(const byte[512]) asm_mul_sqr_lo#0 asm_mul_sqr_lo = { fill( 512, 0) } +(byte[512]) asm_mul_sqr1_hi +(const byte[512]) asm_mul_sqr1_hi#0 asm_mul_sqr1_hi = { fill( 512, 0) } +(byte[512]) asm_mul_sqr1_lo +(const byte[512]) asm_mul_sqr1_lo#0 asm_mul_sqr1_lo = { fill( 512, 0) } +(byte[512]) asm_mul_sqr2_hi +(const byte[512]) asm_mul_sqr2_hi#0 asm_mul_sqr2_hi = { fill( 512, 0) } +(byte[512]) asm_mul_sqr2_lo +(const byte[512]) asm_mul_sqr2_lo#0 asm_mul_sqr2_lo = { fill( 512, 0) } +(byte*) char_cursor +(byte*) char_cursor#1 char_cursor zp ZP_WORD:6 11.0 +(byte*) char_cursor#10 char_cursor zp ZP_WORD:6 0.7142857142857142 +(byte*) char_cursor#17 char_cursor zp ZP_WORD:6 20.0 +(byte*) char_cursor#19 char_cursor zp ZP_WORD:6 3.7 +(byte*) char_cursor#27 char_cursor zp ZP_WORD:6 4.0 +(byte*) char_cursor#39 char_cursor zp ZP_WORD:6 2.0 +(byte*) char_cursor#44 char_cursor zp ZP_WORD:6 4.0 (void()) init_mul_tables() (byte~) init_mul_tables::$2 reg byte a 22.0 (byte~) init_mul_tables::$5 reg byte a 22.0 (byte~) init_mul_tables::$6 reg byte a 22.0 (label) init_mul_tables::@1 +(label) init_mul_tables::@12 (label) init_mul_tables::@2 (label) init_mul_tables::@3 +(label) init_mul_tables::@4 +(label) init_mul_tables::@5 +(label) init_mul_tables::@8 (label) init_mul_tables::@return (byte) init_mul_tables::c (byte) init_mul_tables::c#1 reg byte x 2.357142857142857 (byte) init_mul_tables::c#2 reg byte x 22.0 +(byte) init_mul_tables::dir +(byte) init_mul_tables::dir#2 dir zp ZP_BYTE:10 4.714285714285714 +(byte) init_mul_tables::dir#3 dir zp ZP_BYTE:10 7.333333333333333 (word) init_mul_tables::sqr -(word) init_mul_tables::sqr#1 sqr zp ZP_WORD:7 7.333333333333333 -(word) init_mul_tables::sqr#2 sqr zp ZP_WORD:7 22.0 -(word) init_mul_tables::sqr#3 sqr zp ZP_WORD:7 9.166666666666666 -(word) init_mul_tables::sqr#4 sqr zp ZP_WORD:7 6.6000000000000005 -(byte*) init_mul_tables::sqr_hi -(byte*) init_mul_tables::sqr_hi#1 sqr_hi zp ZP_WORD:4 5.5 -(byte*) init_mul_tables::sqr_hi#2 sqr_hi zp ZP_WORD:4 3.0 -(byte*) init_mul_tables::sqr_lo -(byte*) init_mul_tables::sqr_lo#1 sqr_lo zp ZP_WORD:2 16.5 -(byte*) init_mul_tables::sqr_lo#2 sqr_lo zp ZP_WORD:2 2.5384615384615383 +(word) init_mul_tables::sqr#1 sqr zp ZP_WORD:6 7.333333333333333 +(word) init_mul_tables::sqr#2 sqr zp ZP_WORD:6 22.0 +(word) init_mul_tables::sqr#3 sqr zp ZP_WORD:6 9.166666666666666 +(word) init_mul_tables::sqr#4 sqr zp ZP_WORD:6 6.6000000000000005 +(byte*) init_mul_tables::sqr1_hi +(byte*) init_mul_tables::sqr1_hi#1 sqr1_hi zp ZP_WORD:4 5.5 +(byte*) init_mul_tables::sqr1_hi#2 sqr1_hi zp ZP_WORD:4 3.0 +(byte*) init_mul_tables::sqr1_lo +(byte*) init_mul_tables::sqr1_lo#1 sqr1_lo zp ZP_WORD:2 16.5 +(byte*) init_mul_tables::sqr1_lo#2 sqr1_lo zp ZP_WORD:2 2.5384615384615383 +(byte*) init_mul_tables::sqr2_hi +(byte*) init_mul_tables::sqr2_hi#1 sqr2_hi zp ZP_WORD:4 3.142857142857143 +(byte*) init_mul_tables::sqr2_hi#2 sqr2_hi zp ZP_WORD:4 11.0 +(byte*) init_mul_tables::sqr2_lo +(byte*) init_mul_tables::sqr2_lo#1 sqr2_lo zp ZP_WORD:2 16.5 +(byte*) init_mul_tables::sqr2_lo#2 sqr2_lo zp ZP_WORD:2 4.125 (byte) init_mul_tables::x_2 -(byte) init_mul_tables::x_2#1 x_2 zp ZP_BYTE:6 11.0 -(byte) init_mul_tables::x_2#2 x_2 zp ZP_BYTE:6 4.888888888888889 -(byte) init_mul_tables::x_2#3 x_2 zp ZP_BYTE:6 8.25 +(byte) init_mul_tables::x_2#1 x_2 zp ZP_BYTE:10 11.0 +(byte) init_mul_tables::x_2#2 x_2 zp ZP_BYTE:10 4.888888888888889 +(byte) init_mul_tables::x_2#3 x_2 zp ZP_BYTE:10 8.25 +(byte) init_mul_tables::x_255 +(byte) init_mul_tables::x_255#1 reg byte x 5.5 +(byte) init_mul_tables::x_255#2 reg byte x 11.0 (void()) init_mul_tables_asm() (label) init_mul_tables_asm::@return +(byte*) init_mul_tables_asm::mem +(const byte*) init_mul_tables_asm::mem#0 mem = ((byte*))(byte/word/signed word) 255 +(byte*) line_cursor (void()) main() (label) main::@1 (label) main::@2 (label) main::@return -(byte[512]) mul_sqr_hi -(const byte[512]) mul_sqr_hi#0 mul_sqr_hi = { fill( 512, 0) } -(byte[512]) mul_sqr_lo -(const byte[512]) mul_sqr_lo#0 mul_sqr_lo = { fill( 512, 0) } +(byte[512]) mul_sqr1_hi +(const byte[512]) mul_sqr1_hi#0 mul_sqr1_hi = { fill( 512, 0) } +(byte[512]) mul_sqr1_lo +(const byte[512]) mul_sqr1_lo#0 mul_sqr1_lo = { fill( 512, 0) } +(byte[512]) mul_sqr2_hi +(const byte[512]) mul_sqr2_hi#0 mul_sqr2_hi = { fill( 512, 0) } +(byte[512]) mul_sqr2_lo +(const byte[512]) mul_sqr2_lo#0 mul_sqr2_lo = { fill( 512, 0) } (void()) mul_tables_compare() (label) mul_tables_compare::@1 (label) mul_tables_compare::@2 (label) mul_tables_compare::@3 -(label) mul_tables_compare::@4 -(label) mul_tables_compare::@5 (label) mul_tables_compare::@6 (label) mul_tables_compare::@7 (label) mul_tables_compare::@8 (label) mul_tables_compare::@9 (label) mul_tables_compare::@return -(byte) mul_tables_compare::i -(byte) mul_tables_compare::i#1 reg byte x 16.5 -(byte) mul_tables_compare::i#10 reg byte x 12.222222222222221 +(byte*) mul_tables_compare::asm_sqr +(byte*) mul_tables_compare::asm_sqr#1 asm_sqr zp ZP_WORD:4 7.333333333333333 +(byte*) mul_tables_compare::asm_sqr#2 asm_sqr zp ZP_WORD:4 5.833333333333333 +(byte*) mul_tables_compare::kc_sqr +(byte*) mul_tables_compare::kc_sqr#1 kc_sqr zp ZP_WORD:2 16.5 +(byte*) mul_tables_compare::kc_sqr#2 kc_sqr zp ZP_WORD:2 3.1818181818181817 +(const string) mul_tables_compare::str str = (string) "mul table mismatch at @" +(const string) mul_tables_compare::str1 str1 = (string) " / @" +(void()) print_byte((byte) print_byte::b) +(byte~) print_byte::$0 reg byte y 4.0 +(byte~) print_byte::$2 reg byte a 4.0 +(label) print_byte::@1 +(label) print_byte::@return +(byte) print_byte::b +(byte) print_byte::b#0 reg byte x 4.0 +(byte) print_byte::b#1 reg byte x 4.0 +(byte) print_byte::b#2 reg byte x 2.0 +(byte[]) print_byte::hextab +(const byte[]) print_byte::hextab#0 hextab = { (byte) '0', (byte) '1', (byte) '2', (byte) '3', (byte) '4', (byte) '5', (byte) '6', (byte) '7', (byte) '8', (byte) '9', (byte) 'a', (byte) 'b', (byte) 'c', (byte) 'd', (byte) 'e', (byte) 'f' } +(void()) print_char((byte) print_char::ch) +(label) print_char::@return +(byte) print_char::ch +(byte) print_char::ch#0 reg byte a 4.0 +(byte) print_char::ch#1 reg byte a 4.0 +(byte) print_char::ch#2 reg byte a 6.0 +(void()) print_cls() +(label) print_cls::@1 +(label) print_cls::@return +(byte*) print_cls::sc +(byte*) print_cls::sc#1 sc zp ZP_WORD:6 16.5 +(byte*) print_cls::sc#2 sc zp ZP_WORD:6 16.5 +(void()) print_str((byte*) print_str::str) +(label) print_str::@1 +(label) print_str::@2 +(label) print_str::@return +(byte*) print_str::str +(byte*) print_str::str#0 str zp ZP_WORD:8 22.0 +(byte*) print_str::str#3 str zp ZP_WORD:8 11.5 +(byte*) print_str::str#5 str zp ZP_WORD:8 2.0 +(void()) print_word((word) print_word::w) +(label) print_word::@1 +(label) print_word::@return +(word) print_word::w +(word) print_word::w#0 w zp ZP_WORD:4 4.0 +(word) print_word::w#1 w zp ZP_WORD:4 4.0 +(word) print_word::w#2 w zp ZP_WORD:4 2.6666666666666665 -reg byte x [ mul_tables_compare::i#10 mul_tables_compare::i#1 ] +zp ZP_WORD:2 [ mul_tables_compare::kc_sqr#2 mul_tables_compare::kc_sqr#1 init_mul_tables::sqr1_lo#2 init_mul_tables::sqr1_lo#1 init_mul_tables::sqr2_lo#2 init_mul_tables::sqr2_lo#1 ] +zp ZP_WORD:4 [ mul_tables_compare::asm_sqr#2 mul_tables_compare::asm_sqr#1 print_word::w#2 print_word::w#0 print_word::w#1 init_mul_tables::sqr1_hi#2 init_mul_tables::sqr1_hi#1 init_mul_tables::sqr2_hi#2 init_mul_tables::sqr2_hi#1 ] +reg byte x [ print_byte::b#2 print_byte::b#0 print_byte::b#1 ] +reg byte a [ print_char::ch#2 print_char::ch#0 print_char::ch#1 ] +zp ZP_WORD:6 [ char_cursor#44 char_cursor#27 char_cursor#39 char_cursor#19 char_cursor#17 char_cursor#10 char_cursor#1 print_cls::sc#2 print_cls::sc#1 init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] +zp ZP_WORD:8 [ print_str::str#3 print_str::str#5 print_str::str#0 ] reg byte x [ init_mul_tables::c#2 init_mul_tables::c#1 ] -zp ZP_WORD:2 [ init_mul_tables::sqr_lo#2 init_mul_tables::sqr_lo#1 ] -zp ZP_WORD:4 [ init_mul_tables::sqr_hi#2 init_mul_tables::sqr_hi#1 ] -zp ZP_BYTE:6 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 ] -zp ZP_WORD:7 [ init_mul_tables::sqr#3 init_mul_tables::sqr#4 init_mul_tables::sqr#1 init_mul_tables::sqr#2 ] +zp ZP_BYTE:10 [ init_mul_tables::x_2#3 init_mul_tables::x_2#2 init_mul_tables::x_2#1 init_mul_tables::dir#2 init_mul_tables::dir#3 ] +reg byte x [ init_mul_tables::x_255#2 init_mul_tables::x_255#1 ] +reg byte y [ print_byte::$0 ] +reg byte a [ print_byte::$2 ] reg byte a [ init_mul_tables::$2 ] reg byte a [ init_mul_tables::$5 ] reg byte a [ init_mul_tables::$6 ]