mirror of
https://gitlab.com/camelot/kickc.git
synced 2025-04-09 21:37:31 +00:00
Split multiply tests for performance
This commit is contained in:
parent
8f21ffc0e4
commit
0c7883532e
@ -107,8 +107,13 @@ public class TestPrograms {
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testMultiply() throws IOException, URISyntaxException {
|
||||
compileAndCompare("test-multiply");
|
||||
public void testMultiply8Bit() throws IOException, URISyntaxException {
|
||||
compileAndCompare("test-multiply-8bit");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testMultiply16Bit() throws IOException, URISyntaxException {
|
||||
compileAndCompare("test-multiply-16bit");
|
||||
}
|
||||
|
||||
@Test
|
||||
|
116
src/test/java/dk/camelot64/kickc/test/kc/test-multiply-16bit.kc
Normal file
116
src/test/java/dk/camelot64/kickc/test/kc/test-multiply-16bit.kc
Normal file
@ -0,0 +1,116 @@
|
||||
// Test the fast multiplication library
|
||||
import "print.kc"
|
||||
import "multiply.kc"
|
||||
import "fastmultiply.kc"
|
||||
|
||||
byte* BGCOL = $d021;
|
||||
|
||||
void main() {
|
||||
*BGCOL = 5;
|
||||
print_cls();
|
||||
mulf_init();
|
||||
mul16u_compare();
|
||||
mul16s_compare();
|
||||
}
|
||||
|
||||
// Slow multiplication of unsigned words
|
||||
// Calculate an unsigned multiplication by repeated addition
|
||||
dword muls16u(word a, word b) {
|
||||
dword m = 0;
|
||||
if(a!=0) {
|
||||
for(word i = 0; i!=a; i++) {
|
||||
m = m + b;
|
||||
}
|
||||
}
|
||||
return m;
|
||||
}
|
||||
|
||||
// Slow multiplication of signed words
|
||||
// Perform a signed multiplication by repeated addition/subtraction
|
||||
signed dword muls16s(signed word a, signed word b) {
|
||||
signed dword m = 0;
|
||||
if(a<0) {
|
||||
for(signed word i = 0; i!=a; i--) {
|
||||
m = m - b;
|
||||
}
|
||||
} else if (a>0) {
|
||||
for(signed word j = 0; j!=a; j++) {
|
||||
m = m + b;
|
||||
}
|
||||
}
|
||||
return m;
|
||||
}
|
||||
|
||||
// Perform many possible word multiplications (slow and fast) and compare the results
|
||||
void mul16u_compare() {
|
||||
word a = 0;
|
||||
word b = 0;
|
||||
for(byte i: 0..15) {
|
||||
for(byte j: 0..15) {
|
||||
a=a+3371;
|
||||
b=b+4093;
|
||||
dword ms = muls16u(a, b);
|
||||
dword mn = mul16u(a,b);
|
||||
byte ok = 1;
|
||||
if(ms!=mn) {
|
||||
ok = 0;
|
||||
}
|
||||
if(ok==0) {
|
||||
*BGCOL = 2;
|
||||
mul16u_error(a,b, ms, mn);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
print_str("word multiply results match!@");
|
||||
print_ln();
|
||||
}
|
||||
|
||||
void mul16u_error(word a, word b, dword ms, dword mn) {
|
||||
print_str("word multiply mismatch @");
|
||||
print_word(a);
|
||||
print_str("*@");
|
||||
print_word(b);
|
||||
print_str(" slow:@");
|
||||
print_dword(ms);
|
||||
print_str(" / normal:@");
|
||||
print_dword(mn);
|
||||
print_ln();
|
||||
}
|
||||
|
||||
// Perform many possible word multiplications (slow and fast) and compare the results
|
||||
void mul16s_compare() {
|
||||
signed word a = -$7fff;
|
||||
signed word b = -$7fff;
|
||||
for(byte i: 0..15) {
|
||||
for(byte j: 0..15) {
|
||||
a=a+3371;
|
||||
b=b+4093;
|
||||
signed dword ms = muls16s(a, b);
|
||||
signed dword mn = mul16s(a,b);
|
||||
byte ok = 1;
|
||||
if(ms!=mn) {
|
||||
ok = 0;
|
||||
}
|
||||
if(ok==0) {
|
||||
*BGCOL = 2;
|
||||
mul16s_error(a,b, ms, mn);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
print_str("signed word multiply results match!@");
|
||||
print_ln();
|
||||
}
|
||||
|
||||
void mul16s_error(signed word a, signed word b, signed dword ms, signed dword mn) {
|
||||
print_str("signed word multiply mismatch @");
|
||||
print_sword(a);
|
||||
print_str("*@");
|
||||
print_sword(b);
|
||||
print_str(" slow:@");
|
||||
print_sdword(ms);
|
||||
print_str(" / normal:@");
|
||||
print_sdword(mn);
|
||||
print_ln();
|
||||
}
|
@ -13,8 +13,6 @@ void main() {
|
||||
mulf_tables_cmp();
|
||||
mul8u_compare();
|
||||
mul8s_compare();
|
||||
mul16u_compare();
|
||||
mul16s_compare();
|
||||
}
|
||||
|
||||
// Slow multiplication of unsigned bytes
|
||||
@ -45,36 +43,6 @@ signed word muls8s(signed byte a, signed byte b) {
|
||||
return m;
|
||||
}
|
||||
|
||||
// Slow multiplication of unsigned words
|
||||
// Calculate an unsigned multiplication by repeated addition
|
||||
dword muls16u(word a, word b) {
|
||||
dword m = 0;
|
||||
if(a!=0) {
|
||||
for(word i = 0; i!=a; i++) {
|
||||
m = m + b;
|
||||
}
|
||||
}
|
||||
return m;
|
||||
}
|
||||
|
||||
// Slow multiplication of signed words
|
||||
// Perform a signed multiplication by repeated addition/subtraction
|
||||
signed dword muls16s(signed word a, signed word b) {
|
||||
signed dword m = 0;
|
||||
if(a<0) {
|
||||
for(signed word i = 0; i!=a; i--) {
|
||||
m = m - b;
|
||||
}
|
||||
} else if (a>0) {
|
||||
for(signed word j = 0; j!=a; j++) {
|
||||
m = m + b;
|
||||
}
|
||||
}
|
||||
return m;
|
||||
}
|
||||
|
||||
|
||||
|
||||
// ASM based multiplication tables
|
||||
// <(( x * x )/4)
|
||||
byte[512] align($100) mula_sqr1_lo;
|
||||
@ -232,76 +200,3 @@ void mul8s_error(signed byte a, signed byte b, signed word ms, signed word mn, s
|
||||
print_ln();
|
||||
}
|
||||
|
||||
// Perform many possible word multiplications (slow and fast) and compare the results
|
||||
void mul16u_compare() {
|
||||
word a = 0;
|
||||
word b = 0;
|
||||
for(byte i: 0..15) {
|
||||
for(byte j: 0..15) {
|
||||
a=a+3371;
|
||||
b=b+4093;
|
||||
dword ms = muls16u(a, b);
|
||||
dword mn = mul16u(a,b);
|
||||
byte ok = 1;
|
||||
if(ms!=mn) {
|
||||
ok = 0;
|
||||
}
|
||||
if(ok==0) {
|
||||
*BGCOL = 2;
|
||||
mul16u_error(a,b, ms, mn);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
print_str("word multiply results match!@");
|
||||
print_ln();
|
||||
}
|
||||
|
||||
void mul16u_error(word a, word b, dword ms, dword mn) {
|
||||
print_str("word multiply mismatch @");
|
||||
print_word(a);
|
||||
print_str("*@");
|
||||
print_word(b);
|
||||
print_str(" slow:@");
|
||||
print_dword(ms);
|
||||
print_str(" / normal:@");
|
||||
print_dword(mn);
|
||||
print_ln();
|
||||
}
|
||||
|
||||
// Perform many possible word multiplications (slow and fast) and compare the results
|
||||
void mul16s_compare() {
|
||||
signed word a = -$7fff;
|
||||
signed word b = -$7fff;
|
||||
for(byte i: 0..15) {
|
||||
for(byte j: 0..15) {
|
||||
a=a+3371;
|
||||
b=b+4093;
|
||||
signed dword ms = muls16s(a, b);
|
||||
signed dword mn = mul16s(a,b);
|
||||
byte ok = 1;
|
||||
if(ms!=mn) {
|
||||
ok = 0;
|
||||
}
|
||||
if(ok==0) {
|
||||
*BGCOL = 2;
|
||||
mul16s_error(a,b, ms, mn);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
print_str("signed word multiply results match!@");
|
||||
print_ln();
|
||||
}
|
||||
|
||||
void mul16s_error(signed word a, signed word b, signed dword ms, signed dword mn) {
|
||||
print_str("signed word multiply mismatch @");
|
||||
print_sword(a);
|
||||
print_str("*@");
|
||||
print_sword(b);
|
||||
print_str(" slow:@");
|
||||
print_sdword(ms);
|
||||
print_str(" / normal:@");
|
||||
print_sdword(mn);
|
||||
print_ln();
|
||||
}
|
@ -11,10 +11,6 @@ main: {
|
||||
sta BGCOL
|
||||
jsr print_cls
|
||||
jsr mulf_init
|
||||
jsr mulf_init_asm
|
||||
jsr mulf_tables_cmp
|
||||
jsr mul8u_compare
|
||||
jsr mul8s_compare
|
||||
jsr mul16u_compare
|
||||
jsr mul16s_compare
|
||||
rts
|
||||
@ -567,15 +563,19 @@ mul16u_compare: {
|
||||
inx
|
||||
cpx #$10
|
||||
bne b1
|
||||
lda line_cursor
|
||||
lda #<SCREEN
|
||||
sta char_cursor
|
||||
lda line_cursor+1
|
||||
lda #>SCREEN
|
||||
sta char_cursor+1
|
||||
lda #<str
|
||||
sta print_str.str
|
||||
lda #>str
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
lda #<SCREEN
|
||||
sta line_cursor
|
||||
lda #>SCREEN
|
||||
sta line_cursor+1
|
||||
jsr print_ln
|
||||
jmp breturn
|
||||
str: .text "word multiply results match!@"
|
||||
@ -585,9 +585,9 @@ mul16u_error: {
|
||||
.label b = $14
|
||||
.label ms = $a
|
||||
.label mn = $10
|
||||
lda line_cursor
|
||||
lda #<SCREEN
|
||||
sta char_cursor
|
||||
lda line_cursor+1
|
||||
lda #>SCREEN
|
||||
sta char_cursor+1
|
||||
lda #<str
|
||||
sta print_str.str
|
||||
@ -625,6 +625,10 @@ mul16u_error: {
|
||||
lda mn+3
|
||||
sta print_dword.dw+3
|
||||
jsr print_dword
|
||||
lda #<SCREEN
|
||||
sta line_cursor
|
||||
lda #>SCREEN
|
||||
sta line_cursor+1
|
||||
jsr print_ln
|
||||
rts
|
||||
str: .text "word multiply mismatch @"
|
||||
@ -684,600 +688,6 @@ muls16u: {
|
||||
b1:
|
||||
rts
|
||||
}
|
||||
mul8s_compare: {
|
||||
.label ms = 2
|
||||
.label mf = $14
|
||||
.label mn = 4
|
||||
.label b = $1b
|
||||
.label a = $1a
|
||||
lda #-$80
|
||||
sta a
|
||||
b1:
|
||||
lda #-$80
|
||||
sta b
|
||||
b2:
|
||||
ldx b
|
||||
jsr muls8s
|
||||
ldy a
|
||||
jsr mulf8s
|
||||
ldy b
|
||||
jsr mul8s
|
||||
lda ms
|
||||
cmp mf
|
||||
bne !+
|
||||
lda ms+1
|
||||
cmp mf+1
|
||||
beq b6
|
||||
!:
|
||||
ldx #0
|
||||
jmp b3
|
||||
b6:
|
||||
ldx #1
|
||||
b3:
|
||||
lda ms
|
||||
cmp mn
|
||||
bne !+
|
||||
lda ms+1
|
||||
cmp mn+1
|
||||
beq b4
|
||||
!:
|
||||
ldx #0
|
||||
b4:
|
||||
cpx #0
|
||||
bne b5
|
||||
lda #2
|
||||
sta BGCOL
|
||||
ldx a
|
||||
jsr mul8s_error
|
||||
breturn:
|
||||
rts
|
||||
b5:
|
||||
inc b
|
||||
lda b
|
||||
cmp #-$80
|
||||
bne b2
|
||||
inc a
|
||||
lda a
|
||||
cmp #-$80
|
||||
bne b1
|
||||
lda line_cursor
|
||||
sta char_cursor
|
||||
lda line_cursor+1
|
||||
sta char_cursor+1
|
||||
lda #<str
|
||||
sta print_str.str
|
||||
lda #>str
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_ln
|
||||
jmp breturn
|
||||
str: .text "signed multiply results match!@"
|
||||
}
|
||||
mul8s_error: {
|
||||
.label b = $1b
|
||||
.label ms = 2
|
||||
.label mn = 4
|
||||
.label mf = $14
|
||||
lda line_cursor
|
||||
sta char_cursor
|
||||
lda line_cursor+1
|
||||
sta char_cursor+1
|
||||
lda #<str
|
||||
sta print_str.str
|
||||
lda #>str
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_sbyte
|
||||
lda #<str1
|
||||
sta print_str.str
|
||||
lda #>str1
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
ldx b
|
||||
jsr print_sbyte
|
||||
lda #<str2
|
||||
sta print_str.str
|
||||
lda #>str2
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_sword
|
||||
lda #<str3
|
||||
sta print_str.str
|
||||
lda #>str3
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
lda mn
|
||||
sta print_sword.w
|
||||
lda mn+1
|
||||
sta print_sword.w+1
|
||||
jsr print_sword
|
||||
lda #<str4
|
||||
sta print_str.str
|
||||
lda #>str4
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
lda mf
|
||||
sta print_sword.w
|
||||
lda mf+1
|
||||
sta print_sword.w+1
|
||||
jsr print_sword
|
||||
jsr print_ln
|
||||
rts
|
||||
str: .text "signed multiply mismatch @"
|
||||
str1: .text "*@"
|
||||
str2: .text " slow:@"
|
||||
str3: .text " / normal:@"
|
||||
str4: .text " / fast:@"
|
||||
}
|
||||
print_sbyte: {
|
||||
cpx #0
|
||||
bpl b1
|
||||
lda #'-'
|
||||
jsr print_char
|
||||
txa
|
||||
eor #$ff
|
||||
clc
|
||||
adc #1
|
||||
tax
|
||||
b1:
|
||||
jsr print_byte
|
||||
rts
|
||||
}
|
||||
mul8s: {
|
||||
.label m = 4
|
||||
.label a = $1a
|
||||
.label return = 4
|
||||
tya
|
||||
ldx a
|
||||
jsr mul8u
|
||||
lda a
|
||||
cmp #0
|
||||
bpl b1
|
||||
lda m+1
|
||||
sty $ff
|
||||
sec
|
||||
sbc $ff
|
||||
sta m+1
|
||||
b1:
|
||||
cpy #0
|
||||
bpl b2
|
||||
lda m+1
|
||||
sec
|
||||
sbc a
|
||||
sta m+1
|
||||
b2:
|
||||
rts
|
||||
}
|
||||
mul8u: {
|
||||
.label mb = 8
|
||||
.label res = 4
|
||||
.label return = 4
|
||||
sta mb
|
||||
lda #0
|
||||
sta mb+1
|
||||
sta res
|
||||
sta res+1
|
||||
b1:
|
||||
cpx #0
|
||||
bne b2
|
||||
rts
|
||||
b2:
|
||||
txa
|
||||
and #1
|
||||
cmp #0
|
||||
beq b4
|
||||
lda res
|
||||
clc
|
||||
adc mb
|
||||
sta res
|
||||
lda res+1
|
||||
adc mb+1
|
||||
sta res+1
|
||||
b4:
|
||||
txa
|
||||
lsr
|
||||
tax
|
||||
asl mb
|
||||
rol mb+1
|
||||
jmp b1
|
||||
}
|
||||
mulf8s: {
|
||||
.label m = $14
|
||||
.label b = $1b
|
||||
.label return = $14
|
||||
tya
|
||||
ldx b
|
||||
jsr mulf8u
|
||||
cpy #0
|
||||
bpl b1
|
||||
lda m+1
|
||||
sec
|
||||
sbc b
|
||||
sta m+1
|
||||
b1:
|
||||
lda b
|
||||
cmp #0
|
||||
bpl b2
|
||||
lda m+1
|
||||
sty $ff
|
||||
sec
|
||||
sbc $ff
|
||||
sta m+1
|
||||
b2:
|
||||
rts
|
||||
}
|
||||
mulf8u: {
|
||||
.label memA = $fe
|
||||
.label memB = $ff
|
||||
.label return = $14
|
||||
sta memA
|
||||
stx memB
|
||||
sta sm1+1
|
||||
sta sm3+1
|
||||
eor #$ff
|
||||
sta sm2+1
|
||||
sta sm4+1
|
||||
sec
|
||||
sm1:
|
||||
lda mulf_sqr1_lo,x
|
||||
sm2:
|
||||
sbc mulf_sqr2_lo,x
|
||||
sta memA
|
||||
sm3:
|
||||
lda mulf_sqr1_hi,x
|
||||
sm4:
|
||||
sbc mulf_sqr2_hi,x
|
||||
sta memB
|
||||
lda memA
|
||||
sta return
|
||||
lda memB
|
||||
sta return+1
|
||||
rts
|
||||
}
|
||||
muls8s: {
|
||||
.label m = 2
|
||||
.label return = 2
|
||||
.label a = $1a
|
||||
lda a
|
||||
cmp #0
|
||||
bpl b1
|
||||
lda #0
|
||||
tay
|
||||
sta m
|
||||
sta m+1
|
||||
b2:
|
||||
txa
|
||||
sta $fe
|
||||
ora #$7f
|
||||
bmi !+
|
||||
lda #0
|
||||
!:
|
||||
sta $ff
|
||||
sec
|
||||
lda m
|
||||
sbc $fe
|
||||
sta m
|
||||
lda m+1
|
||||
sbc $ff
|
||||
sta m+1
|
||||
dey
|
||||
cpy a
|
||||
bne b2
|
||||
jmp b3
|
||||
b6:
|
||||
lda #<0
|
||||
sta return
|
||||
sta return+1
|
||||
b3:
|
||||
rts
|
||||
b1:
|
||||
lda a
|
||||
cmp #1
|
||||
bmi b6
|
||||
lda #0
|
||||
tay
|
||||
sta m
|
||||
sta m+1
|
||||
b5:
|
||||
txa
|
||||
sta $fe
|
||||
ora #$7f
|
||||
bmi !+
|
||||
lda #0
|
||||
!:
|
||||
sta $ff
|
||||
clc
|
||||
lda m
|
||||
adc $fe
|
||||
sta m
|
||||
lda m+1
|
||||
adc $ff
|
||||
sta m+1
|
||||
iny
|
||||
cpy a
|
||||
bne b5
|
||||
jmp b3
|
||||
}
|
||||
mul8u_compare: {
|
||||
.label ms = 2
|
||||
.label mf = $14
|
||||
.label mn = 4
|
||||
.label b = $1b
|
||||
.label a = $1a
|
||||
lda #0
|
||||
sta a
|
||||
b1:
|
||||
lda #0
|
||||
sta b
|
||||
b2:
|
||||
ldx b
|
||||
jsr muls8u
|
||||
lda a
|
||||
ldx b
|
||||
jsr mulf8u
|
||||
ldx a
|
||||
lda b
|
||||
jsr mul8u
|
||||
lda ms
|
||||
cmp mf
|
||||
bne !+
|
||||
lda ms+1
|
||||
cmp mf+1
|
||||
beq b6
|
||||
!:
|
||||
ldx #0
|
||||
jmp b3
|
||||
b6:
|
||||
ldx #1
|
||||
b3:
|
||||
lda ms
|
||||
cmp mn
|
||||
bne !+
|
||||
lda ms+1
|
||||
cmp mn+1
|
||||
beq b4
|
||||
!:
|
||||
ldx #0
|
||||
b4:
|
||||
cpx #0
|
||||
bne b5
|
||||
lda #2
|
||||
sta BGCOL
|
||||
ldx a
|
||||
jsr mul8u_error
|
||||
breturn:
|
||||
rts
|
||||
b5:
|
||||
inc b
|
||||
lda b
|
||||
bne b2
|
||||
inc a
|
||||
lda a
|
||||
bne b1
|
||||
lda #<str
|
||||
sta print_str.str
|
||||
lda #>str
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_ln
|
||||
jmp breturn
|
||||
str: .text "multiply results match!@"
|
||||
}
|
||||
mul8u_error: {
|
||||
.label b = $1b
|
||||
.label ms = 2
|
||||
.label mn = 4
|
||||
.label mf = $14
|
||||
lda #<str
|
||||
sta print_str.str
|
||||
lda #>str
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_byte
|
||||
lda #<str1
|
||||
sta print_str.str
|
||||
lda #>str1
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
ldx b
|
||||
jsr print_byte
|
||||
lda #<str2
|
||||
sta print_str.str
|
||||
lda #>str2
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_word
|
||||
lda #<str3
|
||||
sta print_str.str
|
||||
lda #>str3
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
lda mn
|
||||
sta print_word.w
|
||||
lda mn+1
|
||||
sta print_word.w+1
|
||||
jsr print_word
|
||||
lda #<str4
|
||||
sta print_str.str
|
||||
lda #>str4
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
lda mf
|
||||
sta print_word.w
|
||||
lda mf+1
|
||||
sta print_word.w+1
|
||||
jsr print_word
|
||||
jsr print_ln
|
||||
rts
|
||||
str: .text "multiply mismatch @"
|
||||
str1: .text "*@"
|
||||
str2: .text " slow:@"
|
||||
str3: .text " / normal:@"
|
||||
str4: .text " / fast:@"
|
||||
}
|
||||
muls8u: {
|
||||
.label return = 2
|
||||
.label m = 2
|
||||
.label a = $1a
|
||||
lda a
|
||||
beq b3
|
||||
ldy #0
|
||||
tya
|
||||
sta m
|
||||
sta m+1
|
||||
b2:
|
||||
txa
|
||||
clc
|
||||
adc m
|
||||
sta m
|
||||
lda #0
|
||||
adc m+1
|
||||
sta m+1
|
||||
iny
|
||||
cpy a
|
||||
bne b2
|
||||
jmp b1
|
||||
b3:
|
||||
lda #<0
|
||||
sta return
|
||||
sta return+1
|
||||
b1:
|
||||
rts
|
||||
}
|
||||
mulf_tables_cmp: {
|
||||
.label asm_sqr = 2
|
||||
.label kc_sqr = 4
|
||||
lda #<mula_sqr1_lo
|
||||
sta asm_sqr
|
||||
lda #>mula_sqr1_lo
|
||||
sta asm_sqr+1
|
||||
lda #<mulf_sqr1_lo
|
||||
sta kc_sqr
|
||||
lda #>mulf_sqr1_lo
|
||||
sta kc_sqr+1
|
||||
b1:
|
||||
ldy #0
|
||||
lda (kc_sqr),y
|
||||
cmp (asm_sqr),y
|
||||
beq b2
|
||||
lda #2
|
||||
sta BGCOL
|
||||
lda #<SCREEN
|
||||
sta char_cursor
|
||||
lda #>SCREEN
|
||||
sta char_cursor+1
|
||||
lda #<str
|
||||
sta print_str.str
|
||||
lda #>str
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_word
|
||||
lda #<str1
|
||||
sta print_str.str
|
||||
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
|
||||
lda #<SCREEN
|
||||
sta line_cursor
|
||||
lda #>SCREEN
|
||||
sta line_cursor+1
|
||||
breturn:
|
||||
rts
|
||||
b2:
|
||||
inc asm_sqr
|
||||
bne !+
|
||||
inc asm_sqr+1
|
||||
!:
|
||||
inc kc_sqr
|
||||
bne !+
|
||||
inc kc_sqr+1
|
||||
!:
|
||||
lda kc_sqr+1
|
||||
cmp #>mulf_sqr1_lo+$200*4
|
||||
bcc b1
|
||||
bne !+
|
||||
lda kc_sqr
|
||||
cmp #<mulf_sqr1_lo+$200*4
|
||||
bcc b1
|
||||
!:
|
||||
lda #<SCREEN
|
||||
sta char_cursor
|
||||
lda #>SCREEN
|
||||
sta char_cursor+1
|
||||
lda #<str2
|
||||
sta print_str.str
|
||||
lda #>str2
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
lda #<SCREEN
|
||||
sta line_cursor
|
||||
lda #>SCREEN
|
||||
sta line_cursor+1
|
||||
jsr print_ln
|
||||
lda line_cursor
|
||||
sta char_cursor
|
||||
lda line_cursor+1
|
||||
sta char_cursor+1
|
||||
jmp breturn
|
||||
str: .text "multiply table mismatch at @"
|
||||
str1: .text " / @"
|
||||
str2: .text "multiply tables match!@"
|
||||
}
|
||||
mulf_init_asm: {
|
||||
.label mem = $ff
|
||||
ldx #0
|
||||
txa
|
||||
.byte $c9
|
||||
lb1:
|
||||
tya
|
||||
adc #0
|
||||
ml1:
|
||||
sta mula_sqr1_hi,x
|
||||
tay
|
||||
cmp #$40
|
||||
txa
|
||||
ror
|
||||
ml9:
|
||||
adc #0
|
||||
sta ml9+1
|
||||
inx
|
||||
ml0:
|
||||
sta mula_sqr1_lo,x
|
||||
bne lb1
|
||||
inc ml0+2
|
||||
inc ml1+2
|
||||
clc
|
||||
iny
|
||||
bne lb1
|
||||
ldx #0
|
||||
ldy #$ff
|
||||
!:
|
||||
lda mula_sqr1_hi+1,x
|
||||
sta mula_sqr2_hi+$100,x
|
||||
lda mula_sqr1_hi,x
|
||||
sta mula_sqr2_hi,y
|
||||
lda mula_sqr1_lo+1,x
|
||||
sta mula_sqr2_lo+$100,x
|
||||
lda mula_sqr1_lo,x
|
||||
sta mula_sqr2_lo,y
|
||||
dey
|
||||
inx
|
||||
bne !-
|
||||
lda mula_sqr1_lo
|
||||
sta mem
|
||||
lda mula_sqr1_hi
|
||||
sta mem
|
||||
lda mula_sqr2_lo
|
||||
sta mem
|
||||
lda mula_sqr2_hi
|
||||
sta mem
|
||||
rts
|
||||
}
|
||||
mulf_init: {
|
||||
.label sqr1_hi = 4
|
||||
.label sqr = 6
|
||||
@ -1414,11 +824,3 @@ print_cls: {
|
||||
mulf_sqr2_lo: .fill $200, 0
|
||||
.align $100
|
||||
mulf_sqr2_hi: .fill $200, 0
|
||||
.align $100
|
||||
mula_sqr1_lo: .fill $200, 0
|
||||
.align $100
|
||||
mula_sqr1_hi: .fill $200, 0
|
||||
.align $100
|
||||
mula_sqr2_lo: .fill $200, 0
|
||||
.align $100
|
||||
mula_sqr2_hi: .fill $200, 0
|
File diff suppressed because one or more lines are too long
12938
src/test/java/dk/camelot64/kickc/test/ref/test-multiply-16bit.log
Normal file
12938
src/test/java/dk/camelot64/kickc/test/ref/test-multiply-16bit.log
Normal file
File diff suppressed because one or more lines are too long
@ -0,0 +1,386 @@
|
||||
(label) @24
|
||||
(label) @begin
|
||||
(label) @end
|
||||
(byte*) BGCOL
|
||||
(const byte*) BGCOL#0 BGCOL = ((byte*))(word/dword/signed dword) 53281
|
||||
(byte*) SCREEN
|
||||
(const byte*) SCREEN#0 SCREEN = ((byte*))(word/signed word/dword/signed dword) 1024
|
||||
(byte*) char_cursor
|
||||
(byte*) char_cursor#1 char_cursor zp ZP_WORD:14 11.0
|
||||
(byte*) char_cursor#112 char_cursor zp ZP_WORD:14 1.8333333333333333
|
||||
(byte*) char_cursor#113 char_cursor zp ZP_WORD:14 4.75
|
||||
(byte*) char_cursor#114 char_cursor zp ZP_WORD:14 3.0
|
||||
(byte*) char_cursor#116 char_cursor zp ZP_WORD:14 6.0
|
||||
(byte*) char_cursor#117 char_cursor zp ZP_WORD:14 4.0
|
||||
(byte*) char_cursor#118 char_cursor zp ZP_WORD:14 3.0
|
||||
(byte*) char_cursor#120 char_cursor zp ZP_WORD:14 2.0
|
||||
(byte*) char_cursor#130 char_cursor zp ZP_WORD:14 18.0
|
||||
(byte*~) char_cursor#157 char_cursor zp ZP_WORD:14 4.0
|
||||
(byte*~) char_cursor#158 char_cursor zp ZP_WORD:14 4.0
|
||||
(byte*) char_cursor#20 char_cursor zp ZP_WORD:14 0.7179487179487181
|
||||
(byte*) char_cursor#76 char_cursor zp ZP_WORD:14 6.0
|
||||
(byte*) line_cursor
|
||||
(byte*) line_cursor#1 line_cursor zp ZP_WORD:6 0.7068965517241378
|
||||
(byte*) line_cursor#20 line_cursor zp ZP_WORD:6 24.0
|
||||
(byte*) line_cursor#39 line_cursor zp ZP_WORD:6 6.0
|
||||
(void()) main()
|
||||
(label) main::@1
|
||||
(label) main::@2
|
||||
(label) main::@3
|
||||
(label) main::@return
|
||||
(signed dword()) mul16s((signed word) mul16s::a , (signed word) mul16s::b)
|
||||
(word~) mul16s::$12 $12 zp ZP_WORD:8 4.0
|
||||
(word~) mul16s::$16 $16 zp ZP_WORD:8 4.0
|
||||
(word~) mul16s::$17 $17 zp ZP_WORD:8 4.0
|
||||
(word~) mul16s::$6 $6 zp ZP_WORD:8 4.0
|
||||
(label) mul16s::@1
|
||||
(label) mul16s::@2
|
||||
(label) mul16s::@3
|
||||
(label) mul16s::@4
|
||||
(label) mul16s::@6
|
||||
(label) mul16s::@return
|
||||
(signed word) mul16s::a
|
||||
(signed word) mul16s::a#0 a zp ZP_WORD:2 7.357142857142858
|
||||
(signed word) mul16s::b
|
||||
(signed word) mul16s::b#0 b zp ZP_WORD:4 9.363636363636363
|
||||
(dword) mul16s::m
|
||||
(dword) mul16s::m#0 m zp ZP_DWORD:16 2.0
|
||||
(dword) mul16s::m#1 m zp ZP_DWORD:16 4.0
|
||||
(dword) mul16s::m#2 m zp ZP_DWORD:16 4.0
|
||||
(dword) mul16s::m#4 m zp ZP_DWORD:16 6.0
|
||||
(dword) mul16s::m#5 m zp ZP_DWORD:16 2.5
|
||||
(signed dword) mul16s::return
|
||||
(signed dword) mul16s::return#0 return zp ZP_DWORD:16 34.33333333333333
|
||||
(signed dword) mul16s::return#2 return zp ZP_DWORD:16 202.0
|
||||
(void()) mul16s_compare()
|
||||
(label) mul16s_compare::@1
|
||||
(label) mul16s_compare::@10
|
||||
(label) mul16s_compare::@11
|
||||
(label) mul16s_compare::@13
|
||||
(label) mul16s_compare::@2
|
||||
(label) mul16s_compare::@3
|
||||
(label) mul16s_compare::@4
|
||||
(label) mul16s_compare::@5
|
||||
(label) mul16s_compare::@6
|
||||
(label) mul16s_compare::@8
|
||||
(label) mul16s_compare::@9
|
||||
(label) mul16s_compare::@return
|
||||
(signed word) mul16s_compare::a
|
||||
(signed word) mul16s_compare::a#1 a zp ZP_WORD:2 19.857142857142858
|
||||
(signed word) mul16s_compare::a#2 a zp ZP_WORD:2 213.0
|
||||
(signed word) mul16s_compare::a#5 a zp ZP_WORD:2 22.0
|
||||
(signed word) mul16s_compare::b
|
||||
(signed word) mul16s_compare::b#1 b zp ZP_WORD:4 19.857142857142858
|
||||
(signed word) mul16s_compare::b#2 b zp ZP_WORD:4 106.5
|
||||
(signed word) mul16s_compare::b#5 b zp ZP_WORD:4 22.0
|
||||
(byte) mul16s_compare::i
|
||||
(byte) mul16s_compare::i#1 reg byte x 16.5
|
||||
(byte) mul16s_compare::i#9 reg byte x 1.1
|
||||
(byte) mul16s_compare::j
|
||||
(byte) mul16s_compare::j#1 reg byte y 151.5
|
||||
(byte) mul16s_compare::j#2 reg byte y 11.882352941176471
|
||||
(signed dword) mul16s_compare::mn
|
||||
(signed dword) mul16s_compare::mn#0 mn zp ZP_DWORD:16 22.666666666666664
|
||||
(signed dword) mul16s_compare::ms
|
||||
(signed dword) mul16s_compare::ms#0 ms zp ZP_DWORD:10 15.692307692307692
|
||||
(byte) mul16s_compare::ok
|
||||
(byte) mul16s_compare::ok#2 reg byte a 101.0
|
||||
(const string) mul16s_compare::str str = (string) "signed word multiply results match!@"
|
||||
(void()) mul16s_error((signed word) mul16s_error::a , (signed word) mul16s_error::b , (signed dword) mul16s_error::ms , (signed dword) mul16s_error::mn)
|
||||
(label) mul16s_error::@1
|
||||
(label) mul16s_error::@2
|
||||
(label) mul16s_error::@3
|
||||
(label) mul16s_error::@4
|
||||
(label) mul16s_error::@5
|
||||
(label) mul16s_error::@6
|
||||
(label) mul16s_error::@7
|
||||
(label) mul16s_error::@8
|
||||
(label) mul16s_error::@return
|
||||
(signed word) mul16s_error::a
|
||||
(signed word) mul16s_error::a#0 a zp ZP_WORD:2 0.6666666666666666
|
||||
(signed word) mul16s_error::b
|
||||
(signed word) mul16s_error::b#0 b zp ZP_WORD:4 0.4444444444444444
|
||||
(signed dword) mul16s_error::mn
|
||||
(signed dword) mul16s_error::mn#0 mn zp ZP_DWORD:16 0.26666666666666666
|
||||
(signed dword) mul16s_error::ms
|
||||
(signed dword) mul16s_error::ms#0 ms zp ZP_DWORD:10 0.3333333333333333
|
||||
(const string) mul16s_error::str str = (string) "signed word multiply mismatch @"
|
||||
(const string) mul16s_error::str1 str1 = (string) "*@"
|
||||
(const string) mul16s_error::str2 str2 = (string) " slow:@"
|
||||
(const string) mul16s_error::str3 str3 = (string) " / normal:@"
|
||||
(dword()) mul16u((word) mul16u::a , (word) mul16u::b)
|
||||
(byte~) mul16u::$1 reg byte a 2002.0
|
||||
(label) mul16u::@1
|
||||
(label) mul16u::@2
|
||||
(label) mul16u::@4
|
||||
(label) mul16u::@7
|
||||
(label) mul16u::@return
|
||||
(word) mul16u::a
|
||||
(word) mul16u::a#0 a zp ZP_WORD:8 1001.0
|
||||
(word) mul16u::a#2 a zp ZP_WORD:8 101.0
|
||||
(word) mul16u::a#3 a zp ZP_WORD:8 667.6666666666667
|
||||
(word) mul16u::a#6 a zp ZP_WORD:8 52.5
|
||||
(word~) mul16u::a#8 a zp ZP_WORD:8 4.0
|
||||
(word) mul16u::b
|
||||
(word) mul16u::b#1 b zp ZP_WORD:20 202.0
|
||||
(word) mul16u::b#2 b zp ZP_WORD:20 105.0
|
||||
(word~) mul16u::b#3 b zp ZP_WORD:20 2.0
|
||||
(dword) mul16u::mb
|
||||
(dword) mul16u::mb#0 mb zp ZP_DWORD:22 4.0
|
||||
(dword) mul16u::mb#1 mb zp ZP_DWORD:22 2002.0
|
||||
(dword) mul16u::mb#2 mb zp ZP_DWORD:22 429.2857142857143
|
||||
(dword) mul16u::res
|
||||
(dword) mul16u::res#1 res zp ZP_DWORD:16 2002.0
|
||||
(dword) mul16u::res#2 res zp ZP_DWORD:16 443.7142857142857
|
||||
(dword) mul16u::res#6 res zp ZP_DWORD:16 1001.0
|
||||
(dword) mul16u::return
|
||||
(dword) mul16u::return#2 return zp ZP_DWORD:16 4.0
|
||||
(dword) mul16u::return#3 return zp ZP_DWORD:16 202.0
|
||||
(void()) mul16u_compare()
|
||||
(label) mul16u_compare::@1
|
||||
(label) mul16u_compare::@10
|
||||
(label) mul16u_compare::@11
|
||||
(label) mul16u_compare::@13
|
||||
(label) mul16u_compare::@2
|
||||
(label) mul16u_compare::@3
|
||||
(label) mul16u_compare::@4
|
||||
(label) mul16u_compare::@5
|
||||
(label) mul16u_compare::@6
|
||||
(label) mul16u_compare::@8
|
||||
(label) mul16u_compare::@9
|
||||
(label) mul16u_compare::@return
|
||||
(word) mul16u_compare::a
|
||||
(word) mul16u_compare::a#1 a zp ZP_WORD:2 19.857142857142858
|
||||
(word) mul16u_compare::a#2 a zp ZP_WORD:2 213.0
|
||||
(word) mul16u_compare::a#5 a zp ZP_WORD:2 22.0
|
||||
(word) mul16u_compare::b
|
||||
(word) mul16u_compare::b#1 b zp ZP_WORD:20 19.857142857142858
|
||||
(word) mul16u_compare::b#2 b zp ZP_WORD:20 106.5
|
||||
(word) mul16u_compare::b#5 b zp ZP_WORD:20 22.0
|
||||
(byte) mul16u_compare::i
|
||||
(byte) mul16u_compare::i#1 reg byte x 16.5
|
||||
(byte) mul16u_compare::i#9 reg byte x 1.1
|
||||
(byte) mul16u_compare::j
|
||||
(byte) mul16u_compare::j#1 reg byte y 151.5
|
||||
(byte) mul16u_compare::j#2 reg byte y 11.882352941176471
|
||||
(dword) mul16u_compare::mn
|
||||
(dword) mul16u_compare::mn#0 mn zp ZP_DWORD:16 22.666666666666664
|
||||
(dword) mul16u_compare::ms
|
||||
(dword) mul16u_compare::ms#0 ms zp ZP_DWORD:10 15.692307692307692
|
||||
(byte) mul16u_compare::ok
|
||||
(byte) mul16u_compare::ok#2 reg byte a 101.0
|
||||
(const string) mul16u_compare::str str = (string) "word multiply results match!@"
|
||||
(void()) mul16u_error((word) mul16u_error::a , (word) mul16u_error::b , (dword) mul16u_error::ms , (dword) mul16u_error::mn)
|
||||
(label) mul16u_error::@1
|
||||
(label) mul16u_error::@2
|
||||
(label) mul16u_error::@3
|
||||
(label) mul16u_error::@4
|
||||
(label) mul16u_error::@5
|
||||
(label) mul16u_error::@6
|
||||
(label) mul16u_error::@7
|
||||
(label) mul16u_error::@8
|
||||
(label) mul16u_error::@return
|
||||
(word) mul16u_error::a
|
||||
(word) mul16u_error::a#0 a zp ZP_WORD:2 0.6666666666666666
|
||||
(word) mul16u_error::b
|
||||
(word) mul16u_error::b#0 b zp ZP_WORD:20 0.4444444444444444
|
||||
(dword) mul16u_error::mn
|
||||
(dword) mul16u_error::mn#0 mn zp ZP_DWORD:16 0.26666666666666666
|
||||
(dword) mul16u_error::ms
|
||||
(dword) mul16u_error::ms#0 ms zp ZP_DWORD:10 0.3333333333333333
|
||||
(const string) mul16u_error::str str = (string) "word multiply mismatch @"
|
||||
(const string) mul16u_error::str1 str1 = (string) "*@"
|
||||
(const string) mul16u_error::str2 str2 = (string) " slow:@"
|
||||
(const string) mul16u_error::str3 str3 = (string) " / normal:@"
|
||||
(void()) mulf_init()
|
||||
(byte~) mulf_init::$2 reg byte a 22.0
|
||||
(byte~) mulf_init::$5 reg byte a 22.0
|
||||
(byte~) mulf_init::$6 reg byte a 22.0
|
||||
(label) mulf_init::@1
|
||||
(label) mulf_init::@12
|
||||
(label) mulf_init::@2
|
||||
(label) mulf_init::@3
|
||||
(label) mulf_init::@4
|
||||
(label) mulf_init::@5
|
||||
(label) mulf_init::@8
|
||||
(label) mulf_init::@return
|
||||
(byte) mulf_init::c
|
||||
(byte) mulf_init::c#1 reg byte x 2.357142857142857
|
||||
(byte) mulf_init::c#2 reg byte x 22.0
|
||||
(byte) mulf_init::dir
|
||||
(byte) mulf_init::dir#2 dir zp ZP_BYTE:26 4.714285714285714
|
||||
(byte) mulf_init::dir#3 dir zp ZP_BYTE:26 7.333333333333333
|
||||
(word) mulf_init::sqr
|
||||
(word) mulf_init::sqr#1 sqr zp ZP_WORD:6 7.333333333333333
|
||||
(word) mulf_init::sqr#2 sqr zp ZP_WORD:6 22.0
|
||||
(word) mulf_init::sqr#3 sqr zp ZP_WORD:6 9.166666666666666
|
||||
(word) mulf_init::sqr#4 sqr zp ZP_WORD:6 6.6000000000000005
|
||||
(byte*) mulf_init::sqr1_hi
|
||||
(byte*) mulf_init::sqr1_hi#1 sqr1_hi zp ZP_WORD:4 5.5
|
||||
(byte*) mulf_init::sqr1_hi#2 sqr1_hi zp ZP_WORD:4 3.0
|
||||
(byte*) mulf_init::sqr1_lo
|
||||
(byte*) mulf_init::sqr1_lo#1 sqr1_lo zp ZP_WORD:2 16.5
|
||||
(byte*) mulf_init::sqr1_lo#2 sqr1_lo zp ZP_WORD:2 2.5384615384615383
|
||||
(byte*) mulf_init::sqr2_hi
|
||||
(byte*) mulf_init::sqr2_hi#1 sqr2_hi zp ZP_WORD:4 3.142857142857143
|
||||
(byte*) mulf_init::sqr2_hi#2 sqr2_hi zp ZP_WORD:4 11.0
|
||||
(byte*) mulf_init::sqr2_lo
|
||||
(byte*) mulf_init::sqr2_lo#1 sqr2_lo zp ZP_WORD:2 16.5
|
||||
(byte*) mulf_init::sqr2_lo#2 sqr2_lo zp ZP_WORD:2 4.125
|
||||
(byte) mulf_init::x_2
|
||||
(byte) mulf_init::x_2#1 x_2 zp ZP_BYTE:26 11.0
|
||||
(byte) mulf_init::x_2#2 x_2 zp ZP_BYTE:26 4.888888888888889
|
||||
(byte) mulf_init::x_2#3 x_2 zp ZP_BYTE:26 8.25
|
||||
(byte) mulf_init::x_255
|
||||
(byte) mulf_init::x_255#1 reg byte x 5.5
|
||||
(byte) mulf_init::x_255#2 reg byte x 11.0
|
||||
(byte[512]) mulf_sqr1_hi
|
||||
(const byte[512]) mulf_sqr1_hi#0 mulf_sqr1_hi = { fill( 512, 0) }
|
||||
(byte[512]) mulf_sqr1_lo
|
||||
(const byte[512]) mulf_sqr1_lo#0 mulf_sqr1_lo = { fill( 512, 0) }
|
||||
(byte[512]) mulf_sqr2_hi
|
||||
(const byte[512]) mulf_sqr2_hi#0 mulf_sqr2_hi = { fill( 512, 0) }
|
||||
(byte[512]) mulf_sqr2_lo
|
||||
(const byte[512]) mulf_sqr2_lo#0 mulf_sqr2_lo = { fill( 512, 0) }
|
||||
(signed dword()) muls16s((signed word) muls16s::a , (signed word) muls16s::b)
|
||||
(label) muls16s::@1
|
||||
(label) muls16s::@2
|
||||
(label) muls16s::@3
|
||||
(label) muls16s::@5
|
||||
(label) muls16s::@return
|
||||
(signed word) muls16s::a
|
||||
(signed word) muls16s::a#0 a zp ZP_WORD:2 175.58333333333334
|
||||
(signed word) muls16s::b
|
||||
(signed word) muls16s::b#0 b zp ZP_WORD:4 191.1818181818182
|
||||
(signed word) muls16s::i
|
||||
(signed word) muls16s::i#1 i zp ZP_WORD:8 1501.5
|
||||
(signed word) muls16s::i#2 i zp ZP_WORD:8 1001.0
|
||||
(signed word) muls16s::j
|
||||
(signed word) muls16s::j#1 j zp ZP_WORD:8 1501.5
|
||||
(signed word) muls16s::j#2 j zp ZP_WORD:8 1001.0
|
||||
(signed dword) muls16s::m
|
||||
(signed dword) muls16s::m#1 m zp ZP_DWORD:10 1001.0
|
||||
(signed dword) muls16s::m#2 m zp ZP_DWORD:10 1001.0
|
||||
(signed dword) muls16s::m#3 m zp ZP_DWORD:10 2002.0
|
||||
(signed dword) muls16s::m#5 m zp ZP_DWORD:10 2002.0
|
||||
(signed dword) muls16s::return
|
||||
(signed dword) muls16s::return#0 return zp ZP_DWORD:10 701.0
|
||||
(signed dword) muls16s::return#2 return zp ZP_DWORD:10 202.0
|
||||
(dword()) muls16u((word) muls16u::a , (word) muls16u::b)
|
||||
(label) muls16u::@1
|
||||
(label) muls16u::@2
|
||||
(label) muls16u::@return
|
||||
(word) muls16u::a
|
||||
(word) muls16u::a#0 a zp ZP_WORD:2 157.71428571428572
|
||||
(word) muls16u::b
|
||||
(word) muls16u::b#0 b zp ZP_WORD:20 183.66666666666669
|
||||
(word) muls16u::i
|
||||
(word) muls16u::i#1 i zp ZP_WORD:4 1501.5
|
||||
(word) muls16u::i#2 i zp ZP_WORD:4 1001.0
|
||||
(dword) muls16u::m
|
||||
(dword) muls16u::m#1 m zp ZP_DWORD:10 1001.0
|
||||
(dword) muls16u::m#3 m zp ZP_DWORD:10 2002.0
|
||||
(dword) muls16u::return
|
||||
(dword) muls16u::return#0 return zp ZP_DWORD:10 367.33333333333337
|
||||
(dword) muls16u::return#2 return zp ZP_DWORD:10 202.0
|
||||
(void()) print_byte((byte) print_byte::b)
|
||||
(byte~) print_byte::$0 reg byte a 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 string) print_byte::hextab#0 hextab = (string) "0123456789abcdef"
|
||||
(void()) print_char((byte) print_char::ch)
|
||||
(label) print_char::@return
|
||||
(byte) print_char::ch
|
||||
(byte) print_char::ch#2 reg byte a 4.0
|
||||
(byte) print_char::ch#3 reg byte a 4.0
|
||||
(byte) print_char::ch#4 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:2 16.5
|
||||
(byte*) print_cls::sc#2 sc zp ZP_WORD:2 16.5
|
||||
(void()) print_dword((dword) print_dword::dw)
|
||||
(label) print_dword::@1
|
||||
(label) print_dword::@return
|
||||
(dword) print_dword::dw
|
||||
(dword) print_dword::dw#0 dw zp ZP_DWORD:10 4.0
|
||||
(dword) print_dword::dw#1 dw zp ZP_DWORD:10 4.0
|
||||
(dword) print_dword::dw#2 dw zp ZP_DWORD:10 4.0
|
||||
(dword) print_dword::dw#3 dw zp ZP_DWORD:10 3.333333333333333
|
||||
(void()) print_ln()
|
||||
(label) print_ln::@1
|
||||
(label) print_ln::@return
|
||||
(void()) print_sdword((signed dword) print_sdword::dw)
|
||||
(label) print_sdword::@1
|
||||
(label) print_sdword::@2
|
||||
(label) print_sdword::@4
|
||||
(label) print_sdword::@return
|
||||
(signed dword) print_sdword::dw
|
||||
(signed dword) print_sdword::dw#0 dw zp ZP_DWORD:10 4.0
|
||||
(signed dword) print_sdword::dw#1 dw zp ZP_DWORD:10 4.0
|
||||
(signed dword) print_sdword::dw#2 dw zp ZP_DWORD:10 4.0
|
||||
(signed dword) print_sdword::dw#3 dw zp ZP_DWORD:10 2.5
|
||||
(signed dword) print_sdword::dw#4 dw zp ZP_DWORD:10 6.0
|
||||
(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#11 str zp ZP_WORD:8 11.5
|
||||
(byte*) print_str::str#13 str zp ZP_WORD:8 2.0
|
||||
(void()) print_sword((signed word) print_sword::w)
|
||||
(label) print_sword::@1
|
||||
(label) print_sword::@2
|
||||
(label) print_sword::@4
|
||||
(label) print_sword::@return
|
||||
(signed word) print_sword::w
|
||||
(signed word) print_sword::w#0 w zp ZP_WORD:2 4.0
|
||||
(signed word) print_sword::w#1 w zp ZP_WORD:2 4.0
|
||||
(signed word) print_sword::w#2 w zp ZP_WORD:2 4.0
|
||||
(signed word) print_sword::w#3 w zp ZP_WORD:2 2.5
|
||||
(signed word) print_sword::w#4 w zp ZP_WORD:2 4.0
|
||||
(void()) print_word((word) print_word::w)
|
||||
(label) print_word::@1
|
||||
(label) print_word::@return
|
||||
(word) print_word::w
|
||||
(word) print_word::w#1 w zp ZP_WORD:2 4.0
|
||||
(word~) print_word::w#11 w zp ZP_WORD:2 4.0
|
||||
(word) print_word::w#2 w zp ZP_WORD:2 4.0
|
||||
(word) print_word::w#3 w zp ZP_WORD:2 4.0
|
||||
(word) print_word::w#4 w zp ZP_WORD:2 4.0
|
||||
(word) print_word::w#5 w zp ZP_WORD:2 4.666666666666666
|
||||
|
||||
reg byte x [ mul16s_compare::i#9 mul16s_compare::i#1 ]
|
||||
zp ZP_WORD:2 [ mul16s_compare::a#2 mul16s_compare::a#5 mul16s_compare::a#1 muls16s::a#0 mul16s::a#0 mul16s_error::a#0 print_sword::w#4 print_sword::w#3 print_sword::w#1 print_sword::w#2 print_sword::w#0 print_word::w#5 print_word::w#3 print_word::w#4 print_word::w#1 print_word::w#2 print_word::w#11 mul16u_error::a#0 mul16u_compare::a#2 mul16u_compare::a#5 mul16u_compare::a#1 muls16u::a#0 mulf_init::sqr1_lo#2 mulf_init::sqr1_lo#1 mulf_init::sqr2_lo#2 mulf_init::sqr2_lo#1 print_cls::sc#2 print_cls::sc#1 ]
|
||||
zp ZP_WORD:4 [ mul16s_compare::b#2 mul16s_compare::b#5 mul16s_compare::b#1 muls16s::b#0 mul16s::b#0 mul16s_error::b#0 muls16u::i#2 muls16u::i#1 mulf_init::sqr1_hi#2 mulf_init::sqr1_hi#1 mulf_init::sqr2_hi#2 mulf_init::sqr2_hi#1 ]
|
||||
reg byte y [ mul16s_compare::j#2 mul16s_compare::j#1 ]
|
||||
reg byte a [ mul16s_compare::ok#2 ]
|
||||
zp ZP_WORD:6 [ line_cursor#20 line_cursor#39 line_cursor#1 mulf_init::sqr#3 mulf_init::sqr#4 mulf_init::sqr#1 mulf_init::sqr#2 ]
|
||||
zp ZP_WORD:8 [ print_str::str#11 print_str::str#13 print_str::str#0 mul16u::a#3 mul16u::a#6 mul16u::a#8 mul16u::a#2 mul16u::a#0 muls16s::i#2 muls16s::i#1 muls16s::j#2 muls16s::j#1 mul16s::$6 mul16s::$16 mul16s::$12 mul16s::$17 ]
|
||||
zp ZP_DWORD:10 [ print_sdword::dw#4 print_sdword::dw#3 print_sdword::dw#1 print_sdword::dw#2 print_sdword::dw#0 print_dword::dw#3 print_dword::dw#1 print_dword::dw#2 print_dword::dw#0 mul16s_error::ms#0 mul16s_compare::ms#0 muls16s::return#2 muls16s::m#5 muls16s::return#0 muls16s::m#3 muls16s::m#1 muls16s::m#2 mul16u_error::ms#0 mul16u_compare::ms#0 muls16u::return#2 muls16u::return#0 muls16u::m#3 muls16u::m#1 ]
|
||||
reg byte x [ print_byte::b#2 print_byte::b#0 print_byte::b#1 ]
|
||||
reg byte a [ print_char::ch#4 print_char::ch#2 print_char::ch#3 ]
|
||||
zp ZP_WORD:14 [ char_cursor#76 char_cursor#120 char_cursor#116 char_cursor#117 char_cursor#118 char_cursor#130 char_cursor#157 char_cursor#158 char_cursor#113 char_cursor#112 char_cursor#20 char_cursor#1 char_cursor#114 ]
|
||||
zp ZP_DWORD:16 [ mul16s::m#4 mul16s::m#5 mul16s::m#1 mul16s::m#0 mul16s::m#2 mul16u::return#2 mul16u::res#2 mul16u::res#6 mul16u::res#1 mul16s::return#0 mul16s::return#2 mul16s_compare::mn#0 mul16s_error::mn#0 mul16u::return#3 mul16u_compare::mn#0 mul16u_error::mn#0 ]
|
||||
zp ZP_WORD:20 [ mul16u::b#2 mul16u::b#3 mul16u::b#1 mul16u_compare::b#2 mul16u_compare::b#5 mul16u_compare::b#1 muls16u::b#0 mul16u_error::b#0 ]
|
||||
zp ZP_DWORD:22 [ mul16u::mb#2 mul16u::mb#0 mul16u::mb#1 ]
|
||||
reg byte x [ mul16u_compare::i#9 mul16u_compare::i#1 ]
|
||||
reg byte y [ mul16u_compare::j#2 mul16u_compare::j#1 ]
|
||||
reg byte a [ mul16u_compare::ok#2 ]
|
||||
reg byte x [ mulf_init::c#2 mulf_init::c#1 ]
|
||||
zp ZP_BYTE:26 [ mulf_init::x_2#3 mulf_init::x_2#2 mulf_init::x_2#1 mulf_init::dir#2 mulf_init::dir#3 ]
|
||||
reg byte x [ mulf_init::x_255#2 mulf_init::x_255#1 ]
|
||||
reg byte a [ print_byte::$0 ]
|
||||
reg byte a [ print_byte::$2 ]
|
||||
reg byte a [ mul16u::$1 ]
|
||||
reg byte a [ mulf_init::$2 ]
|
||||
reg byte a [ mulf_init::$5 ]
|
||||
reg byte a [ mulf_init::$6 ]
|
853
src/test/java/dk/camelot64/kickc/test/ref/test-multiply-8bit.asm
Normal file
853
src/test/java/dk/camelot64/kickc/test/ref/test-multiply-8bit.asm
Normal file
@ -0,0 +1,853 @@
|
||||
.pc = $801 "Basic"
|
||||
:BasicUpstart(main)
|
||||
.pc = $80d "Program"
|
||||
.label SCREEN = $400
|
||||
.label BGCOL = $d021
|
||||
.label char_cursor = $a
|
||||
.label line_cursor = 4
|
||||
jsr main
|
||||
main: {
|
||||
lda #5
|
||||
sta BGCOL
|
||||
jsr print_cls
|
||||
jsr mulf_init
|
||||
jsr mulf_init_asm
|
||||
jsr mulf_tables_cmp
|
||||
jsr mul8u_compare
|
||||
jsr mul8s_compare
|
||||
rts
|
||||
}
|
||||
mul8s_compare: {
|
||||
.label ms = 8
|
||||
.label mf = $e
|
||||
.label mn = $c
|
||||
.label b = 3
|
||||
.label a = 2
|
||||
lda #-$80
|
||||
sta a
|
||||
b1:
|
||||
lda #-$80
|
||||
sta b
|
||||
b2:
|
||||
ldx b
|
||||
jsr muls8s
|
||||
ldy a
|
||||
jsr mulf8s
|
||||
ldy b
|
||||
jsr mul8s
|
||||
lda ms
|
||||
cmp mf
|
||||
bne !+
|
||||
lda ms+1
|
||||
cmp mf+1
|
||||
beq b6
|
||||
!:
|
||||
ldx #0
|
||||
jmp b3
|
||||
b6:
|
||||
ldx #1
|
||||
b3:
|
||||
lda ms
|
||||
cmp mn
|
||||
bne !+
|
||||
lda ms+1
|
||||
cmp mn+1
|
||||
beq b4
|
||||
!:
|
||||
ldx #0
|
||||
b4:
|
||||
cpx #0
|
||||
bne b5
|
||||
lda #2
|
||||
sta BGCOL
|
||||
ldx a
|
||||
jsr mul8s_error
|
||||
breturn:
|
||||
rts
|
||||
b5:
|
||||
inc b
|
||||
lda b
|
||||
cmp #-$80
|
||||
bne b2
|
||||
inc a
|
||||
lda a
|
||||
cmp #-$80
|
||||
bne b1
|
||||
lda line_cursor
|
||||
sta char_cursor
|
||||
lda line_cursor+1
|
||||
sta char_cursor+1
|
||||
lda #<str
|
||||
sta print_str.str
|
||||
lda #>str
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_ln
|
||||
jmp breturn
|
||||
str: .text "signed multiply results match!@"
|
||||
}
|
||||
print_ln: {
|
||||
b1:
|
||||
lda line_cursor
|
||||
clc
|
||||
adc #$28
|
||||
sta line_cursor
|
||||
bcc !+
|
||||
inc line_cursor+1
|
||||
!:
|
||||
lda line_cursor+1
|
||||
cmp char_cursor+1
|
||||
bcc b1
|
||||
bne !+
|
||||
lda line_cursor
|
||||
cmp char_cursor
|
||||
bcc b1
|
||||
!:
|
||||
rts
|
||||
}
|
||||
print_str: {
|
||||
.label str = 6
|
||||
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
|
||||
}
|
||||
mul8s_error: {
|
||||
.label b = 3
|
||||
.label ms = 8
|
||||
.label mn = $c
|
||||
.label mf = $e
|
||||
lda line_cursor
|
||||
sta char_cursor
|
||||
lda line_cursor+1
|
||||
sta char_cursor+1
|
||||
lda #<str
|
||||
sta print_str.str
|
||||
lda #>str
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_sbyte
|
||||
lda #<str1
|
||||
sta print_str.str
|
||||
lda #>str1
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
ldx b
|
||||
jsr print_sbyte
|
||||
lda #<str2
|
||||
sta print_str.str
|
||||
lda #>str2
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_sword
|
||||
lda #<str3
|
||||
sta print_str.str
|
||||
lda #>str3
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
lda mn
|
||||
sta print_sword.w
|
||||
lda mn+1
|
||||
sta print_sword.w+1
|
||||
jsr print_sword
|
||||
lda #<str4
|
||||
sta print_str.str
|
||||
lda #>str4
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
lda mf
|
||||
sta print_sword.w
|
||||
lda mf+1
|
||||
sta print_sword.w+1
|
||||
jsr print_sword
|
||||
jsr print_ln
|
||||
rts
|
||||
str: .text "signed multiply mismatch @"
|
||||
str1: .text "*@"
|
||||
str2: .text " slow:@"
|
||||
str3: .text " / normal:@"
|
||||
str4: .text " / fast:@"
|
||||
}
|
||||
print_sword: {
|
||||
.label w = 8
|
||||
lda w+1
|
||||
bpl b1
|
||||
lda #'-'
|
||||
jsr print_char
|
||||
sec
|
||||
lda w
|
||||
eor #$ff
|
||||
adc #0
|
||||
sta w
|
||||
lda w+1
|
||||
eor #$ff
|
||||
adc #0
|
||||
sta w+1
|
||||
b1:
|
||||
jsr print_word
|
||||
rts
|
||||
}
|
||||
print_word: {
|
||||
.label w = 8
|
||||
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
|
||||
tay
|
||||
lda hextab,y
|
||||
jsr print_char
|
||||
rts
|
||||
hextab: .text "0123456789abcdef"
|
||||
}
|
||||
print_char: {
|
||||
ldy #0
|
||||
sta (char_cursor),y
|
||||
inc char_cursor
|
||||
bne !+
|
||||
inc char_cursor+1
|
||||
!:
|
||||
rts
|
||||
}
|
||||
print_sbyte: {
|
||||
cpx #0
|
||||
bpl b1
|
||||
lda #'-'
|
||||
jsr print_char
|
||||
txa
|
||||
eor #$ff
|
||||
clc
|
||||
adc #1
|
||||
tax
|
||||
b1:
|
||||
jsr print_byte
|
||||
rts
|
||||
}
|
||||
mul8s: {
|
||||
.label m = $c
|
||||
.label a = 2
|
||||
.label return = $c
|
||||
tya
|
||||
ldx a
|
||||
jsr mul8u
|
||||
lda a
|
||||
cmp #0
|
||||
bpl b1
|
||||
lda m+1
|
||||
sty $ff
|
||||
sec
|
||||
sbc $ff
|
||||
sta m+1
|
||||
b1:
|
||||
cpy #0
|
||||
bpl b2
|
||||
lda m+1
|
||||
sec
|
||||
sbc a
|
||||
sta m+1
|
||||
b2:
|
||||
rts
|
||||
}
|
||||
mul8u: {
|
||||
.label mb = 6
|
||||
.label res = $c
|
||||
.label return = $c
|
||||
sta mb
|
||||
lda #0
|
||||
sta mb+1
|
||||
sta res
|
||||
sta res+1
|
||||
b1:
|
||||
cpx #0
|
||||
bne b2
|
||||
rts
|
||||
b2:
|
||||
txa
|
||||
and #1
|
||||
cmp #0
|
||||
beq b4
|
||||
lda res
|
||||
clc
|
||||
adc mb
|
||||
sta res
|
||||
lda res+1
|
||||
adc mb+1
|
||||
sta res+1
|
||||
b4:
|
||||
txa
|
||||
lsr
|
||||
tax
|
||||
asl mb
|
||||
rol mb+1
|
||||
jmp b1
|
||||
}
|
||||
mulf8s: {
|
||||
.label m = $e
|
||||
.label b = 3
|
||||
.label return = $e
|
||||
tya
|
||||
ldx b
|
||||
jsr mulf8u
|
||||
cpy #0
|
||||
bpl b1
|
||||
lda m+1
|
||||
sec
|
||||
sbc b
|
||||
sta m+1
|
||||
b1:
|
||||
lda b
|
||||
cmp #0
|
||||
bpl b2
|
||||
lda m+1
|
||||
sty $ff
|
||||
sec
|
||||
sbc $ff
|
||||
sta m+1
|
||||
b2:
|
||||
rts
|
||||
}
|
||||
mulf8u: {
|
||||
.label memA = $fe
|
||||
.label memB = $ff
|
||||
.label return = $e
|
||||
sta memA
|
||||
stx memB
|
||||
sta sm1+1
|
||||
sta sm3+1
|
||||
eor #$ff
|
||||
sta sm2+1
|
||||
sta sm4+1
|
||||
sec
|
||||
sm1:
|
||||
lda mulf_sqr1_lo,x
|
||||
sm2:
|
||||
sbc mulf_sqr2_lo,x
|
||||
sta memA
|
||||
sm3:
|
||||
lda mulf_sqr1_hi,x
|
||||
sm4:
|
||||
sbc mulf_sqr2_hi,x
|
||||
sta memB
|
||||
lda memA
|
||||
sta return
|
||||
lda memB
|
||||
sta return+1
|
||||
rts
|
||||
}
|
||||
muls8s: {
|
||||
.label m = 8
|
||||
.label return = 8
|
||||
.label a = 2
|
||||
lda a
|
||||
cmp #0
|
||||
bpl b1
|
||||
lda #0
|
||||
tay
|
||||
sta m
|
||||
sta m+1
|
||||
b2:
|
||||
txa
|
||||
sta $fe
|
||||
ora #$7f
|
||||
bmi !+
|
||||
lda #0
|
||||
!:
|
||||
sta $ff
|
||||
sec
|
||||
lda m
|
||||
sbc $fe
|
||||
sta m
|
||||
lda m+1
|
||||
sbc $ff
|
||||
sta m+1
|
||||
dey
|
||||
cpy a
|
||||
bne b2
|
||||
jmp b3
|
||||
b6:
|
||||
lda #<0
|
||||
sta return
|
||||
sta return+1
|
||||
b3:
|
||||
rts
|
||||
b1:
|
||||
lda a
|
||||
cmp #1
|
||||
bmi b6
|
||||
lda #0
|
||||
tay
|
||||
sta m
|
||||
sta m+1
|
||||
b5:
|
||||
txa
|
||||
sta $fe
|
||||
ora #$7f
|
||||
bmi !+
|
||||
lda #0
|
||||
!:
|
||||
sta $ff
|
||||
clc
|
||||
lda m
|
||||
adc $fe
|
||||
sta m
|
||||
lda m+1
|
||||
adc $ff
|
||||
sta m+1
|
||||
iny
|
||||
cpy a
|
||||
bne b5
|
||||
jmp b3
|
||||
}
|
||||
mul8u_compare: {
|
||||
.label ms = 8
|
||||
.label mf = $e
|
||||
.label mn = $c
|
||||
.label b = 3
|
||||
.label a = 2
|
||||
lda #0
|
||||
sta a
|
||||
b1:
|
||||
lda #0
|
||||
sta b
|
||||
b2:
|
||||
ldx b
|
||||
jsr muls8u
|
||||
lda a
|
||||
ldx b
|
||||
jsr mulf8u
|
||||
ldx a
|
||||
lda b
|
||||
jsr mul8u
|
||||
lda ms
|
||||
cmp mf
|
||||
bne !+
|
||||
lda ms+1
|
||||
cmp mf+1
|
||||
beq b6
|
||||
!:
|
||||
ldx #0
|
||||
jmp b3
|
||||
b6:
|
||||
ldx #1
|
||||
b3:
|
||||
lda ms
|
||||
cmp mn
|
||||
bne !+
|
||||
lda ms+1
|
||||
cmp mn+1
|
||||
beq b4
|
||||
!:
|
||||
ldx #0
|
||||
b4:
|
||||
cpx #0
|
||||
bne b5
|
||||
lda #2
|
||||
sta BGCOL
|
||||
ldx a
|
||||
jsr mul8u_error
|
||||
breturn:
|
||||
rts
|
||||
b5:
|
||||
inc b
|
||||
lda b
|
||||
bne b2
|
||||
inc a
|
||||
lda a
|
||||
bne b1
|
||||
lda #<str
|
||||
sta print_str.str
|
||||
lda #>str
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_ln
|
||||
jmp breturn
|
||||
str: .text "multiply results match!@"
|
||||
}
|
||||
mul8u_error: {
|
||||
.label b = 3
|
||||
.label ms = 8
|
||||
.label mn = $c
|
||||
.label mf = $e
|
||||
lda #<str
|
||||
sta print_str.str
|
||||
lda #>str
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_byte
|
||||
lda #<str1
|
||||
sta print_str.str
|
||||
lda #>str1
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
ldx b
|
||||
jsr print_byte
|
||||
lda #<str2
|
||||
sta print_str.str
|
||||
lda #>str2
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_word
|
||||
lda #<str3
|
||||
sta print_str.str
|
||||
lda #>str3
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
lda mn
|
||||
sta print_word.w
|
||||
lda mn+1
|
||||
sta print_word.w+1
|
||||
jsr print_word
|
||||
lda #<str4
|
||||
sta print_str.str
|
||||
lda #>str4
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
lda mf
|
||||
sta print_word.w
|
||||
lda mf+1
|
||||
sta print_word.w+1
|
||||
jsr print_word
|
||||
jsr print_ln
|
||||
rts
|
||||
str: .text "multiply mismatch @"
|
||||
str1: .text "*@"
|
||||
str2: .text " slow:@"
|
||||
str3: .text " / normal:@"
|
||||
str4: .text " / fast:@"
|
||||
}
|
||||
muls8u: {
|
||||
.label return = 8
|
||||
.label m = 8
|
||||
.label a = 2
|
||||
lda a
|
||||
beq b3
|
||||
ldy #0
|
||||
tya
|
||||
sta m
|
||||
sta m+1
|
||||
b2:
|
||||
txa
|
||||
clc
|
||||
adc m
|
||||
sta m
|
||||
lda #0
|
||||
adc m+1
|
||||
sta m+1
|
||||
iny
|
||||
cpy a
|
||||
bne b2
|
||||
jmp b1
|
||||
b3:
|
||||
lda #<0
|
||||
sta return
|
||||
sta return+1
|
||||
b1:
|
||||
rts
|
||||
}
|
||||
mulf_tables_cmp: {
|
||||
.label asm_sqr = 8
|
||||
.label kc_sqr = 4
|
||||
lda #<mula_sqr1_lo
|
||||
sta asm_sqr
|
||||
lda #>mula_sqr1_lo
|
||||
sta asm_sqr+1
|
||||
lda #<mulf_sqr1_lo
|
||||
sta kc_sqr
|
||||
lda #>mulf_sqr1_lo
|
||||
sta kc_sqr+1
|
||||
b1:
|
||||
ldy #0
|
||||
lda (kc_sqr),y
|
||||
cmp (asm_sqr),y
|
||||
beq b2
|
||||
lda #2
|
||||
sta BGCOL
|
||||
lda #<SCREEN
|
||||
sta char_cursor
|
||||
lda #>SCREEN
|
||||
sta char_cursor+1
|
||||
lda #<str
|
||||
sta print_str.str
|
||||
lda #>str
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
jsr print_word
|
||||
lda #<str1
|
||||
sta print_str.str
|
||||
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
|
||||
lda #<SCREEN
|
||||
sta line_cursor
|
||||
lda #>SCREEN
|
||||
sta line_cursor+1
|
||||
breturn:
|
||||
rts
|
||||
b2:
|
||||
inc asm_sqr
|
||||
bne !+
|
||||
inc asm_sqr+1
|
||||
!:
|
||||
inc kc_sqr
|
||||
bne !+
|
||||
inc kc_sqr+1
|
||||
!:
|
||||
lda kc_sqr+1
|
||||
cmp #>mulf_sqr1_lo+$200*4
|
||||
bcc b1
|
||||
bne !+
|
||||
lda kc_sqr
|
||||
cmp #<mulf_sqr1_lo+$200*4
|
||||
bcc b1
|
||||
!:
|
||||
lda #<SCREEN
|
||||
sta char_cursor
|
||||
lda #>SCREEN
|
||||
sta char_cursor+1
|
||||
lda #<str2
|
||||
sta print_str.str
|
||||
lda #>str2
|
||||
sta print_str.str+1
|
||||
jsr print_str
|
||||
lda #<SCREEN
|
||||
sta line_cursor
|
||||
lda #>SCREEN
|
||||
sta line_cursor+1
|
||||
jsr print_ln
|
||||
lda line_cursor
|
||||
sta char_cursor
|
||||
lda line_cursor+1
|
||||
sta char_cursor+1
|
||||
jmp breturn
|
||||
str: .text "multiply table mismatch at @"
|
||||
str1: .text " / @"
|
||||
str2: .text "multiply tables match!@"
|
||||
}
|
||||
mulf_init_asm: {
|
||||
.label mem = $ff
|
||||
ldx #0
|
||||
txa
|
||||
.byte $c9
|
||||
lb1:
|
||||
tya
|
||||
adc #0
|
||||
ml1:
|
||||
sta mula_sqr1_hi,x
|
||||
tay
|
||||
cmp #$40
|
||||
txa
|
||||
ror
|
||||
ml9:
|
||||
adc #0
|
||||
sta ml9+1
|
||||
inx
|
||||
ml0:
|
||||
sta mula_sqr1_lo,x
|
||||
bne lb1
|
||||
inc ml0+2
|
||||
inc ml1+2
|
||||
clc
|
||||
iny
|
||||
bne lb1
|
||||
ldx #0
|
||||
ldy #$ff
|
||||
!:
|
||||
lda mula_sqr1_hi+1,x
|
||||
sta mula_sqr2_hi+$100,x
|
||||
lda mula_sqr1_hi,x
|
||||
sta mula_sqr2_hi,y
|
||||
lda mula_sqr1_lo+1,x
|
||||
sta mula_sqr2_lo+$100,x
|
||||
lda mula_sqr1_lo,x
|
||||
sta mula_sqr2_lo,y
|
||||
dey
|
||||
inx
|
||||
bne !-
|
||||
lda mula_sqr1_lo
|
||||
sta mem
|
||||
lda mula_sqr1_hi
|
||||
sta mem
|
||||
lda mula_sqr2_lo
|
||||
sta mem
|
||||
lda mula_sqr2_hi
|
||||
sta mem
|
||||
rts
|
||||
}
|
||||
mulf_init: {
|
||||
.label sqr1_hi = 6
|
||||
.label sqr = 8
|
||||
.label sqr1_lo = 4
|
||||
.label x_2 = 2
|
||||
.label sqr2_hi = 6
|
||||
.label sqr2_lo = 4
|
||||
.label dir = 2
|
||||
lda #0
|
||||
sta x_2
|
||||
lda #<mulf_sqr1_hi+1
|
||||
sta sqr1_hi
|
||||
lda #>mulf_sqr1_hi+1
|
||||
sta sqr1_hi+1
|
||||
lda #<mulf_sqr1_lo+1
|
||||
sta sqr1_lo
|
||||
lda #>mulf_sqr1_lo+1
|
||||
sta sqr1_lo+1
|
||||
lda #<0
|
||||
sta sqr
|
||||
sta sqr+1
|
||||
tax
|
||||
b1:
|
||||
inx
|
||||
txa
|
||||
and #1
|
||||
cmp #0
|
||||
bne b2
|
||||
inc x_2
|
||||
inc sqr
|
||||
bne !+
|
||||
inc sqr+1
|
||||
!:
|
||||
b2:
|
||||
lda sqr
|
||||
ldy #0
|
||||
sta (sqr1_lo),y
|
||||
lda sqr+1
|
||||
sta (sqr1_hi),y
|
||||
inc sqr1_hi
|
||||
bne !+
|
||||
inc sqr1_hi+1
|
||||
!:
|
||||
lda x_2
|
||||
clc
|
||||
adc sqr
|
||||
sta sqr
|
||||
lda #0
|
||||
adc sqr+1
|
||||
sta sqr+1
|
||||
inc sqr1_lo
|
||||
bne !+
|
||||
inc sqr1_lo+1
|
||||
!:
|
||||
lda sqr1_lo+1
|
||||
cmp #>mulf_sqr1_lo+$200
|
||||
bne b1
|
||||
lda sqr1_lo
|
||||
cmp #<mulf_sqr1_lo+$200
|
||||
bne b1
|
||||
lda #$ff
|
||||
sta dir
|
||||
lda #<mulf_sqr2_hi
|
||||
sta sqr2_hi
|
||||
lda #>mulf_sqr2_hi
|
||||
sta sqr2_hi+1
|
||||
lda #<mulf_sqr2_lo
|
||||
sta sqr2_lo
|
||||
lda #>mulf_sqr2_lo
|
||||
sta sqr2_lo+1
|
||||
ldx #-1
|
||||
b3:
|
||||
lda mulf_sqr1_lo,x
|
||||
ldy #0
|
||||
sta (sqr2_lo),y
|
||||
lda mulf_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 #>mulf_sqr2_lo+$1ff
|
||||
bne b3
|
||||
lda sqr2_lo
|
||||
cmp #<mulf_sqr2_lo+$1ff
|
||||
bne b3
|
||||
lda mulf_sqr1_lo+$100
|
||||
sta mulf_sqr2_lo+$1ff
|
||||
lda mulf_sqr1_hi+$100
|
||||
sta mulf_sqr2_hi+$1ff
|
||||
rts
|
||||
}
|
||||
print_cls: {
|
||||
.label sc = 4
|
||||
lda #<SCREEN
|
||||
sta sc
|
||||
lda #>SCREEN
|
||||
sta sc+1
|
||||
b1:
|
||||
lda #' '
|
||||
ldy #0
|
||||
sta (sc),y
|
||||
inc sc
|
||||
bne !+
|
||||
inc sc+1
|
||||
!:
|
||||
lda sc+1
|
||||
cmp #>SCREEN+$3e8
|
||||
bne b1
|
||||
lda sc
|
||||
cmp #<SCREEN+$3e8
|
||||
bne b1
|
||||
rts
|
||||
}
|
||||
.align $100
|
||||
mulf_sqr1_lo: .fill $200, 0
|
||||
.align $100
|
||||
mulf_sqr1_hi: .fill $200, 0
|
||||
.align $100
|
||||
mulf_sqr2_lo: .fill $200, 0
|
||||
.align $100
|
||||
mulf_sqr2_hi: .fill $200, 0
|
||||
.align $100
|
||||
mula_sqr1_lo: .fill $200, 0
|
||||
.align $100
|
||||
mula_sqr1_hi: .fill $200, 0
|
||||
.align $100
|
||||
mula_sqr2_lo: .fill $200, 0
|
||||
.align $100
|
||||
mula_sqr2_hi: .fill $200, 0
|
641
src/test/java/dk/camelot64/kickc/test/ref/test-multiply-8bit.cfg
Normal file
641
src/test/java/dk/camelot64/kickc/test/ref/test-multiply-8bit.cfg
Normal file
File diff suppressed because one or more lines are too long
15173
src/test/java/dk/camelot64/kickc/test/ref/test-multiply-8bit.log
Normal file
15173
src/test/java/dk/camelot64/kickc/test/ref/test-multiply-8bit.log
Normal file
File diff suppressed because one or more lines are too long
480
src/test/java/dk/camelot64/kickc/test/ref/test-multiply-8bit.sym
Normal file
480
src/test/java/dk/camelot64/kickc/test/ref/test-multiply-8bit.sym
Normal file
@ -0,0 +1,480 @@
|
||||
(label) @26
|
||||
(label) @begin
|
||||
(label) @end
|
||||
(byte*) BGCOL
|
||||
(const byte*) BGCOL#0 BGCOL = ((byte*))(word/dword/signed dword) 53281
|
||||
(byte*) SCREEN
|
||||
(const byte*) SCREEN#0 SCREEN = ((byte*))(word/signed word/dword/signed dword) 1024
|
||||
(byte*) char_cursor
|
||||
(byte*) char_cursor#1 char_cursor zp ZP_WORD:10 11.0
|
||||
(byte*) char_cursor#130 char_cursor zp ZP_WORD:10 1.5750000000000004
|
||||
(byte*) char_cursor#131 char_cursor zp ZP_WORD:10 5.25
|
||||
(byte*) char_cursor#132 char_cursor zp ZP_WORD:10 3.0
|
||||
(byte*) char_cursor#134 char_cursor zp ZP_WORD:10 3.0
|
||||
(byte*) char_cursor#136 char_cursor zp ZP_WORD:10 7.0
|
||||
(byte*) char_cursor#137 char_cursor zp ZP_WORD:10 3.9999999999999996
|
||||
(byte*) char_cursor#149 char_cursor zp ZP_WORD:10 28.0
|
||||
(byte*) char_cursor#17 char_cursor zp ZP_WORD:10 0.8095238095238098
|
||||
(byte*~) char_cursor#188 char_cursor zp ZP_WORD:10 4.0
|
||||
(byte*~) char_cursor#189 char_cursor zp ZP_WORD:10 4.0
|
||||
(byte*~) char_cursor#222 char_cursor zp ZP_WORD:10 4.0
|
||||
(byte*) char_cursor#30 char_cursor zp ZP_WORD:10 0.1951219512195122
|
||||
(byte*) char_cursor#82 char_cursor zp ZP_WORD:10 6.0
|
||||
(byte*) line_cursor
|
||||
(byte*) line_cursor#1 line_cursor zp ZP_WORD:4 0.6338028169014083
|
||||
(byte*) line_cursor#10 line_cursor zp ZP_WORD:4 0.09523809523809523
|
||||
(byte*) line_cursor#23 line_cursor zp ZP_WORD:4 24.0
|
||||
(byte*) line_cursor#45 line_cursor zp ZP_WORD:4 10.0
|
||||
(void()) main()
|
||||
(label) main::@1
|
||||
(label) main::@2
|
||||
(label) main::@3
|
||||
(label) main::@4
|
||||
(label) main::@5
|
||||
(label) main::@return
|
||||
(signed word()) mul8s((signed byte) mul8s::a , (signed byte) mul8s::b)
|
||||
(byte~) mul8s::$12 reg byte a 4.0
|
||||
(byte/signed byte/word/signed word/dword/signed dword~) mul8s::$16 reg byte a 4.0
|
||||
(byte/signed byte/word/signed word/dword/signed dword~) mul8s::$17 reg byte a 4.0
|
||||
(byte~) mul8s::$6 reg byte a 4.0
|
||||
(label) mul8s::@1
|
||||
(label) mul8s::@2
|
||||
(label) mul8s::@3
|
||||
(label) mul8s::@4
|
||||
(label) mul8s::@6
|
||||
(label) mul8s::@return
|
||||
(signed byte) mul8s::a
|
||||
(signed byte) mul8s::a#0 a zp ZP_BYTE:2 7.357142857142858
|
||||
(signed byte) mul8s::b
|
||||
(signed byte) mul8s::b#0 reg byte y 9.363636363636363
|
||||
(word) mul8s::m
|
||||
(word) mul8s::m#0 m zp ZP_WORD:12 2.0
|
||||
(word) mul8s::m#1 m zp ZP_WORD:12 4.0
|
||||
(word) mul8s::m#2 m zp ZP_WORD:12 4.0
|
||||
(word) mul8s::m#4 m zp ZP_WORD:12 1.3333333333333333
|
||||
(word) mul8s::m#5 m zp ZP_WORD:12 2.5
|
||||
(signed word) mul8s::return
|
||||
(signed word) mul8s::return#2 return zp ZP_WORD:12 202.0
|
||||
(void()) mul8s_compare()
|
||||
(label) mul8s_compare::@1
|
||||
(label) mul8s_compare::@10
|
||||
(label) mul8s_compare::@11
|
||||
(label) mul8s_compare::@12
|
||||
(label) mul8s_compare::@13
|
||||
(label) mul8s_compare::@14
|
||||
(label) mul8s_compare::@16
|
||||
(label) mul8s_compare::@2
|
||||
(label) mul8s_compare::@20
|
||||
(label) mul8s_compare::@3
|
||||
(label) mul8s_compare::@4
|
||||
(label) mul8s_compare::@5
|
||||
(label) mul8s_compare::@6
|
||||
(label) mul8s_compare::@8
|
||||
(label) mul8s_compare::@return
|
||||
(signed byte) mul8s_compare::a
|
||||
(signed byte) mul8s_compare::a#1 a zp ZP_BYTE:2 16.5
|
||||
(signed byte) mul8s_compare::a#7 a zp ZP_BYTE:2 12.11111111111111
|
||||
(signed byte) mul8s_compare::b
|
||||
(signed byte) mul8s_compare::b#1 b zp ZP_BYTE:3 151.5
|
||||
(signed byte) mul8s_compare::b#10 b zp ZP_BYTE:3 20.279999999999998
|
||||
(signed word) mul8s_compare::mf
|
||||
(signed word) mul8s_compare::mf#0 mf zp ZP_WORD:14 11.333333333333332
|
||||
(signed word) mul8s_compare::mn
|
||||
(signed word) mul8s_compare::mn#0 mn zp ZP_WORD:12 17.0
|
||||
(signed word) mul8s_compare::ms
|
||||
(signed word) mul8s_compare::ms#0 ms zp ZP_WORD:8 14.523809523809522
|
||||
(byte) mul8s_compare::ok
|
||||
(byte) mul8s_compare::ok#3 reg byte x 202.0
|
||||
(byte) mul8s_compare::ok#4 reg byte x 33.666666666666664
|
||||
(const string) mul8s_compare::str str = (string) "signed multiply results match!@"
|
||||
(void()) mul8s_error((signed byte) mul8s_error::a , (signed byte) mul8s_error::b , (signed word) mul8s_error::ms , (signed word) mul8s_error::mn , (signed word) mul8s_error::mf)
|
||||
(label) mul8s_error::@1
|
||||
(label) mul8s_error::@10
|
||||
(label) mul8s_error::@2
|
||||
(label) mul8s_error::@3
|
||||
(label) mul8s_error::@4
|
||||
(label) mul8s_error::@5
|
||||
(label) mul8s_error::@6
|
||||
(label) mul8s_error::@7
|
||||
(label) mul8s_error::@8
|
||||
(label) mul8s_error::@9
|
||||
(label) mul8s_error::@return
|
||||
(signed byte) mul8s_error::a
|
||||
(signed byte) mul8s_error::a#0 reg byte x 0.5714285714285714
|
||||
(signed byte) mul8s_error::b
|
||||
(signed byte) mul8s_error::b#0 b zp ZP_BYTE:3 0.4
|
||||
(signed word) mul8s_error::mf
|
||||
(signed word) mul8s_error::mf#0 mf zp ZP_WORD:14 0.21052631578947367
|
||||
(signed word) mul8s_error::mn
|
||||
(signed word) mul8s_error::mn#0 mn zp ZP_WORD:12 0.25
|
||||
(signed word) mul8s_error::ms
|
||||
(signed word) mul8s_error::ms#0 ms zp ZP_WORD:8 0.3076923076923077
|
||||
(const string) mul8s_error::str str = (string) "signed multiply mismatch @"
|
||||
(const string) mul8s_error::str1 str1 = (string) "*@"
|
||||
(const string) mul8s_error::str2 str2 = (string) " slow:@"
|
||||
(const string) mul8s_error::str3 str3 = (string) " / normal:@"
|
||||
(const string) mul8s_error::str4 str4 = (string) " / fast:@"
|
||||
(word()) mul8u((byte) mul8u::a , (byte) mul8u::b)
|
||||
(byte~) mul8u::$1 reg byte a 2002.0
|
||||
(label) mul8u::@1
|
||||
(label) mul8u::@2
|
||||
(label) mul8u::@4
|
||||
(label) mul8u::@7
|
||||
(label) mul8u::@return
|
||||
(byte) mul8u::a
|
||||
(byte) mul8u::a#0 reg byte x 1001.0
|
||||
(byte) mul8u::a#2 reg byte x 101.0
|
||||
(byte) mul8u::a#3 reg byte x 667.6666666666667
|
||||
(byte) mul8u::a#6 reg byte x 52.5
|
||||
(byte~) mul8u::a#8 reg byte x 4.0
|
||||
(byte) mul8u::b
|
||||
(byte) mul8u::b#1 reg byte a 202.0
|
||||
(byte) mul8u::b#2 reg byte a 105.0
|
||||
(byte~) mul8u::b#3 reg byte a 2.0
|
||||
(word) mul8u::mb
|
||||
(word) mul8u::mb#0 mb zp ZP_WORD:6 4.0
|
||||
(word) mul8u::mb#1 mb zp ZP_WORD:6 2002.0
|
||||
(word) mul8u::mb#2 mb zp ZP_WORD:6 429.2857142857143
|
||||
(word) mul8u::res
|
||||
(word) mul8u::res#1 res zp ZP_WORD:12 2002.0
|
||||
(word) mul8u::res#2 res zp ZP_WORD:12 443.7142857142857
|
||||
(word) mul8u::res#6 res zp ZP_WORD:12 1001.0
|
||||
(word) mul8u::return
|
||||
(word) mul8u::return#2 return zp ZP_WORD:12 4.0
|
||||
(word) mul8u::return#3 return zp ZP_WORD:12 202.0
|
||||
(void()) mul8u_compare()
|
||||
(label) mul8u_compare::@1
|
||||
(label) mul8u_compare::@10
|
||||
(label) mul8u_compare::@11
|
||||
(label) mul8u_compare::@12
|
||||
(label) mul8u_compare::@13
|
||||
(label) mul8u_compare::@14
|
||||
(label) mul8u_compare::@16
|
||||
(label) mul8u_compare::@2
|
||||
(label) mul8u_compare::@20
|
||||
(label) mul8u_compare::@3
|
||||
(label) mul8u_compare::@4
|
||||
(label) mul8u_compare::@5
|
||||
(label) mul8u_compare::@6
|
||||
(label) mul8u_compare::@8
|
||||
(label) mul8u_compare::@return
|
||||
(byte) mul8u_compare::a
|
||||
(byte) mul8u_compare::a#1 a zp ZP_BYTE:2 16.5
|
||||
(byte) mul8u_compare::a#7 a zp ZP_BYTE:2 12.11111111111111
|
||||
(byte) mul8u_compare::b
|
||||
(byte) mul8u_compare::b#1 b zp ZP_BYTE:3 151.5
|
||||
(byte) mul8u_compare::b#10 b zp ZP_BYTE:3 20.279999999999998
|
||||
(word) mul8u_compare::mf
|
||||
(word) mul8u_compare::mf#0 mf zp ZP_WORD:14 11.333333333333332
|
||||
(word) mul8u_compare::mn
|
||||
(word) mul8u_compare::mn#0 mn zp ZP_WORD:12 17.0
|
||||
(word) mul8u_compare::ms
|
||||
(word) mul8u_compare::ms#0 ms zp ZP_WORD:8 14.523809523809522
|
||||
(byte) mul8u_compare::ok
|
||||
(byte) mul8u_compare::ok#3 reg byte x 202.0
|
||||
(byte) mul8u_compare::ok#4 reg byte x 33.666666666666664
|
||||
(const string) mul8u_compare::str str = (string) "multiply results match!@"
|
||||
(void()) mul8u_error((byte) mul8u_error::a , (byte) mul8u_error::b , (word) mul8u_error::ms , (word) mul8u_error::mn , (word) mul8u_error::mf)
|
||||
(label) mul8u_error::@1
|
||||
(label) mul8u_error::@10
|
||||
(label) mul8u_error::@2
|
||||
(label) mul8u_error::@3
|
||||
(label) mul8u_error::@4
|
||||
(label) mul8u_error::@5
|
||||
(label) mul8u_error::@6
|
||||
(label) mul8u_error::@7
|
||||
(label) mul8u_error::@8
|
||||
(label) mul8u_error::@9
|
||||
(label) mul8u_error::@return
|
||||
(byte) mul8u_error::a
|
||||
(byte) mul8u_error::a#0 reg byte x 0.5714285714285714
|
||||
(byte) mul8u_error::b
|
||||
(byte) mul8u_error::b#0 b zp ZP_BYTE:3 0.4
|
||||
(word) mul8u_error::mf
|
||||
(word) mul8u_error::mf#0 mf zp ZP_WORD:14 0.21052631578947367
|
||||
(word) mul8u_error::mn
|
||||
(word) mul8u_error::mn#0 mn zp ZP_WORD:12 0.25
|
||||
(word) mul8u_error::ms
|
||||
(word) mul8u_error::ms#0 ms zp ZP_WORD:8 0.3076923076923077
|
||||
(const string) mul8u_error::str str = (string) "multiply mismatch @"
|
||||
(const string) mul8u_error::str1 str1 = (string) "*@"
|
||||
(const string) mul8u_error::str2 str2 = (string) " slow:@"
|
||||
(const string) mul8u_error::str3 str3 = (string) " / normal:@"
|
||||
(const string) mul8u_error::str4 str4 = (string) " / fast:@"
|
||||
(byte[512]) mula_sqr1_hi
|
||||
(const byte[512]) mula_sqr1_hi#0 mula_sqr1_hi = { fill( 512, 0) }
|
||||
(byte[512]) mula_sqr1_lo
|
||||
(const byte[512]) mula_sqr1_lo#0 mula_sqr1_lo = { fill( 512, 0) }
|
||||
(byte[512]) mula_sqr2_hi
|
||||
(const byte[512]) mula_sqr2_hi#0 mula_sqr2_hi = { fill( 512, 0) }
|
||||
(byte[512]) mula_sqr2_lo
|
||||
(const byte[512]) mula_sqr2_lo#0 mula_sqr2_lo = { fill( 512, 0) }
|
||||
(signed word()) mulf8s((signed byte) mulf8s::a , (signed byte) mulf8s::b)
|
||||
(byte~) mulf8s::$12 reg byte a 4.0
|
||||
(byte/signed byte/word/signed word/dword/signed dword~) mulf8s::$16 reg byte a 4.0
|
||||
(byte/signed byte/word/signed word/dword/signed dword~) mulf8s::$17 reg byte a 4.0
|
||||
(byte~) mulf8s::$6 reg byte a 4.0
|
||||
(label) mulf8s::@1
|
||||
(label) mulf8s::@2
|
||||
(label) mulf8s::@3
|
||||
(label) mulf8s::@4
|
||||
(label) mulf8s::@6
|
||||
(label) mulf8s::@return
|
||||
(signed byte) mulf8s::a
|
||||
(signed byte) mulf8s::a#0 reg byte y 7.357142857142858
|
||||
(signed byte) mulf8s::b
|
||||
(signed byte) mulf8s::b#0 b zp ZP_BYTE:3 9.363636363636363
|
||||
(word) mulf8s::m
|
||||
(word) mulf8s::m#0 m zp ZP_WORD:14 2.0
|
||||
(word) mulf8s::m#1 m zp ZP_WORD:14 4.0
|
||||
(word) mulf8s::m#2 m zp ZP_WORD:14 4.0
|
||||
(word) mulf8s::m#4 m zp ZP_WORD:14 1.3333333333333333
|
||||
(word) mulf8s::m#5 m zp ZP_WORD:14 2.5
|
||||
(signed word) mulf8s::return
|
||||
(signed word) mulf8s::return#2 return zp ZP_WORD:14 202.0
|
||||
(word()) mulf8u((byte) mulf8u::a , (byte) mulf8u::b)
|
||||
(label) mulf8u::@return
|
||||
(byte) mulf8u::a
|
||||
(byte) mulf8u::a#1 reg byte a 101.0
|
||||
(byte) mulf8u::a#2 reg byte a 105.0
|
||||
(byte~) mulf8u::a#4 reg byte a 2.0
|
||||
(byte) mulf8u::b
|
||||
(byte) mulf8u::b#1 reg byte x 202.0
|
||||
(byte) mulf8u::b#2 reg byte x 52.5
|
||||
(byte~) mulf8u::b#4 reg byte x 4.0
|
||||
(byte*) mulf8u::memA
|
||||
(const byte*) mulf8u::memA#0 memA = ((byte*))(byte/word/signed word/dword/signed dword) 254
|
||||
(byte*) mulf8u::memB
|
||||
(const byte*) mulf8u::memB#0 memB = ((byte*))(byte/word/signed word/dword/signed dword) 255
|
||||
(word) mulf8u::return
|
||||
(word) mulf8u::return#0 return zp ZP_WORD:14 26.25
|
||||
(word) mulf8u::return#2 return zp ZP_WORD:14 4.0
|
||||
(word) mulf8u::return#3 return zp ZP_WORD:14 202.0
|
||||
(void()) mulf_init()
|
||||
(byte~) mulf_init::$2 reg byte a 22.0
|
||||
(byte~) mulf_init::$5 reg byte a 22.0
|
||||
(byte~) mulf_init::$6 reg byte a 22.0
|
||||
(label) mulf_init::@1
|
||||
(label) mulf_init::@12
|
||||
(label) mulf_init::@2
|
||||
(label) mulf_init::@3
|
||||
(label) mulf_init::@4
|
||||
(label) mulf_init::@5
|
||||
(label) mulf_init::@8
|
||||
(label) mulf_init::@return
|
||||
(byte) mulf_init::c
|
||||
(byte) mulf_init::c#1 reg byte x 2.357142857142857
|
||||
(byte) mulf_init::c#2 reg byte x 22.0
|
||||
(byte) mulf_init::dir
|
||||
(byte) mulf_init::dir#2 dir zp ZP_BYTE:2 4.714285714285714
|
||||
(byte) mulf_init::dir#3 dir zp ZP_BYTE:2 7.333333333333333
|
||||
(word) mulf_init::sqr
|
||||
(word) mulf_init::sqr#1 sqr zp ZP_WORD:8 7.333333333333333
|
||||
(word) mulf_init::sqr#2 sqr zp ZP_WORD:8 22.0
|
||||
(word) mulf_init::sqr#3 sqr zp ZP_WORD:8 9.166666666666666
|
||||
(word) mulf_init::sqr#4 sqr zp ZP_WORD:8 6.6000000000000005
|
||||
(byte*) mulf_init::sqr1_hi
|
||||
(byte*) mulf_init::sqr1_hi#1 sqr1_hi zp ZP_WORD:6 5.5
|
||||
(byte*) mulf_init::sqr1_hi#2 sqr1_hi zp ZP_WORD:6 3.0
|
||||
(byte*) mulf_init::sqr1_lo
|
||||
(byte*) mulf_init::sqr1_lo#1 sqr1_lo zp ZP_WORD:4 16.5
|
||||
(byte*) mulf_init::sqr1_lo#2 sqr1_lo zp ZP_WORD:4 2.5384615384615383
|
||||
(byte*) mulf_init::sqr2_hi
|
||||
(byte*) mulf_init::sqr2_hi#1 sqr2_hi zp ZP_WORD:6 3.142857142857143
|
||||
(byte*) mulf_init::sqr2_hi#2 sqr2_hi zp ZP_WORD:6 11.0
|
||||
(byte*) mulf_init::sqr2_lo
|
||||
(byte*) mulf_init::sqr2_lo#1 sqr2_lo zp ZP_WORD:4 16.5
|
||||
(byte*) mulf_init::sqr2_lo#2 sqr2_lo zp ZP_WORD:4 4.125
|
||||
(byte) mulf_init::x_2
|
||||
(byte) mulf_init::x_2#1 x_2 zp ZP_BYTE:2 11.0
|
||||
(byte) mulf_init::x_2#2 x_2 zp ZP_BYTE:2 4.888888888888889
|
||||
(byte) mulf_init::x_2#3 x_2 zp ZP_BYTE:2 8.25
|
||||
(byte) mulf_init::x_255
|
||||
(byte) mulf_init::x_255#1 reg byte x 5.5
|
||||
(byte) mulf_init::x_255#2 reg byte x 11.0
|
||||
(void()) mulf_init_asm()
|
||||
(label) mulf_init_asm::@return
|
||||
(byte*) mulf_init_asm::mem
|
||||
(const byte*) mulf_init_asm::mem#0 mem = ((byte*))(byte/word/signed word/dword/signed dword) 255
|
||||
(byte[512]) mulf_sqr1_hi
|
||||
(const byte[512]) mulf_sqr1_hi#0 mulf_sqr1_hi = { fill( 512, 0) }
|
||||
(byte[512]) mulf_sqr1_lo
|
||||
(const byte[512]) mulf_sqr1_lo#0 mulf_sqr1_lo = { fill( 512, 0) }
|
||||
(byte[512]) mulf_sqr2_hi
|
||||
(const byte[512]) mulf_sqr2_hi#0 mulf_sqr2_hi = { fill( 512, 0) }
|
||||
(byte[512]) mulf_sqr2_lo
|
||||
(const byte[512]) mulf_sqr2_lo#0 mulf_sqr2_lo = { fill( 512, 0) }
|
||||
(void()) mulf_tables_cmp()
|
||||
(label) mulf_tables_cmp::@1
|
||||
(label) mulf_tables_cmp::@10
|
||||
(label) mulf_tables_cmp::@2
|
||||
(label) mulf_tables_cmp::@3
|
||||
(label) mulf_tables_cmp::@5
|
||||
(label) mulf_tables_cmp::@6
|
||||
(label) mulf_tables_cmp::@7
|
||||
(label) mulf_tables_cmp::@8
|
||||
(label) mulf_tables_cmp::@return
|
||||
(byte*) mulf_tables_cmp::asm_sqr
|
||||
(byte*) mulf_tables_cmp::asm_sqr#1 asm_sqr zp ZP_WORD:8 7.333333333333333
|
||||
(byte*) mulf_tables_cmp::asm_sqr#2 asm_sqr zp ZP_WORD:8 8.25
|
||||
(byte*) mulf_tables_cmp::kc_sqr
|
||||
(byte*) mulf_tables_cmp::kc_sqr#1 kc_sqr zp ZP_WORD:4 16.5
|
||||
(byte*) mulf_tables_cmp::kc_sqr#2 kc_sqr zp ZP_WORD:4 3.666666666666667
|
||||
(const string) mulf_tables_cmp::str str = (string) "multiply table mismatch at @"
|
||||
(const string) mulf_tables_cmp::str1 str1 = (string) " / @"
|
||||
(const string) mulf_tables_cmp::str2 str2 = (string) "multiply tables match!@"
|
||||
(signed word()) muls8s((signed byte) muls8s::a , (signed byte) muls8s::b)
|
||||
(label) muls8s::@1
|
||||
(label) muls8s::@2
|
||||
(label) muls8s::@3
|
||||
(label) muls8s::@5
|
||||
(label) muls8s::@return
|
||||
(signed byte) muls8s::a
|
||||
(signed byte) muls8s::a#0 a zp ZP_BYTE:2 175.58333333333334
|
||||
(signed byte) muls8s::b
|
||||
(signed byte) muls8s::b#0 reg byte x 191.1818181818182
|
||||
(signed byte) muls8s::i
|
||||
(signed byte) muls8s::i#1 reg byte y 1501.5
|
||||
(signed byte) muls8s::i#2 reg byte y 1001.0
|
||||
(signed byte) muls8s::j
|
||||
(signed byte) muls8s::j#1 reg byte y 1501.5
|
||||
(signed byte) muls8s::j#2 reg byte y 1001.0
|
||||
(signed word) muls8s::m
|
||||
(signed word) muls8s::m#1 m zp ZP_WORD:8 1001.0
|
||||
(signed word) muls8s::m#2 m zp ZP_WORD:8 1001.0
|
||||
(signed word) muls8s::m#3 m zp ZP_WORD:8 2002.0
|
||||
(signed word) muls8s::m#5 m zp ZP_WORD:8 2002.0
|
||||
(signed word) muls8s::return
|
||||
(signed word) muls8s::return#0 return zp ZP_WORD:8 701.0
|
||||
(signed word) muls8s::return#2 return zp ZP_WORD:8 202.0
|
||||
(word()) muls8u((byte) muls8u::a , (byte) muls8u::b)
|
||||
(label) muls8u::@1
|
||||
(label) muls8u::@2
|
||||
(label) muls8u::@return
|
||||
(byte) muls8u::a
|
||||
(byte) muls8u::a#0 a zp ZP_BYTE:2 157.71428571428572
|
||||
(byte) muls8u::b
|
||||
(byte) muls8u::b#0 reg byte x 183.66666666666669
|
||||
(byte) muls8u::i
|
||||
(byte) muls8u::i#1 reg byte y 1501.5
|
||||
(byte) muls8u::i#2 reg byte y 1001.0
|
||||
(word) muls8u::m
|
||||
(word) muls8u::m#1 m zp ZP_WORD:8 1001.0
|
||||
(word) muls8u::m#3 m zp ZP_WORD:8 2002.0
|
||||
(word) muls8u::return
|
||||
(word) muls8u::return#0 return zp ZP_WORD:8 367.33333333333337
|
||||
(word) muls8u::return#2 return zp ZP_WORD:8 202.0
|
||||
(void()) print_byte((byte) print_byte::b)
|
||||
(byte~) print_byte::$0 reg byte a 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#1 reg byte x 4.0
|
||||
(byte) print_byte::b#2 reg byte x 4.0
|
||||
(byte) print_byte::b#3 reg byte x 4.0
|
||||
(byte) print_byte::b#4 reg byte x 4.0
|
||||
(byte) print_byte::b#5 reg byte x 3.5
|
||||
(byte~) print_byte::b#9 reg byte x 4.0
|
||||
(byte[]) print_byte::hextab
|
||||
(const string) print_byte::hextab#0 hextab = (string) "0123456789abcdef"
|
||||
(void()) print_char((byte) print_char::ch)
|
||||
(label) print_char::@return
|
||||
(byte) print_char::ch
|
||||
(byte) print_char::ch#2 reg byte a 4.0
|
||||
(byte) print_char::ch#3 reg byte a 4.0
|
||||
(byte) print_char::ch#4 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:4 16.5
|
||||
(byte*) print_cls::sc#2 sc zp ZP_WORD:4 16.5
|
||||
(void()) print_ln()
|
||||
(label) print_ln::@1
|
||||
(label) print_ln::@return
|
||||
(void()) print_sbyte((signed byte) print_sbyte::b)
|
||||
(label) print_sbyte::@1
|
||||
(label) print_sbyte::@2
|
||||
(label) print_sbyte::@4
|
||||
(label) print_sbyte::@return
|
||||
(signed byte) print_sbyte::b
|
||||
(signed byte) print_sbyte::b#0 reg byte x 4.0
|
||||
(signed byte) print_sbyte::b#1 reg byte x 4.0
|
||||
(signed byte) print_sbyte::b#2 reg byte x 4.0
|
||||
(signed byte) print_sbyte::b#3 reg byte x 2.5
|
||||
(signed byte) print_sbyte::b#4 reg byte x 4.0
|
||||
(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:6 22.0
|
||||
(byte*) print_str::str#16 str zp ZP_WORD:6 11.5
|
||||
(byte*) print_str::str#18 str zp ZP_WORD:6 2.0
|
||||
(void()) print_sword((signed word) print_sword::w)
|
||||
(label) print_sword::@1
|
||||
(label) print_sword::@2
|
||||
(label) print_sword::@4
|
||||
(label) print_sword::@return
|
||||
(signed word) print_sword::w
|
||||
(signed word) print_sword::w#0 w zp ZP_WORD:8 4.0
|
||||
(signed word) print_sword::w#1 w zp ZP_WORD:8 4.0
|
||||
(signed word) print_sword::w#2 w zp ZP_WORD:8 4.0
|
||||
(signed word) print_sword::w#3 w zp ZP_WORD:8 4.0
|
||||
(signed word) print_sword::w#4 w zp ZP_WORD:8 3.0
|
||||
(signed word) print_sword::w#5 w zp ZP_WORD:8 4.0
|
||||
(void()) print_word((word) print_word::w)
|
||||
(label) print_word::@1
|
||||
(label) print_word::@return
|
||||
(word) print_word::w
|
||||
(word~) print_word::w#11 w zp ZP_WORD:8 4.0
|
||||
(word~) print_word::w#12 w zp ZP_WORD:8 4.0
|
||||
(word~) print_word::w#13 w zp ZP_WORD:8 4.0
|
||||
(word) print_word::w#3 w zp ZP_WORD:8 4.0
|
||||
(word) print_word::w#4 w zp ZP_WORD:8 4.0
|
||||
(word) print_word::w#5 w zp ZP_WORD:8 4.0
|
||||
(word) print_word::w#6 w zp ZP_WORD:8 5.333333333333333
|
||||
|
||||
zp ZP_BYTE:2 [ mul8s_compare::a#7 mul8s_compare::a#1 muls8s::a#0 mul8s::a#0 mul8u_compare::a#7 mul8u_compare::a#1 muls8u::a#0 mulf_init::x_2#3 mulf_init::x_2#2 mulf_init::x_2#1 mulf_init::dir#2 mulf_init::dir#3 ]
|
||||
zp ZP_BYTE:3 [ mul8s_compare::b#10 mul8s_compare::b#1 mulf8s::b#0 mul8s_error::b#0 mul8u_compare::b#10 mul8u_compare::b#1 mul8u_error::b#0 ]
|
||||
reg byte x [ mul8s_compare::ok#3 mul8s_compare::ok#4 ]
|
||||
zp ZP_WORD:4 [ line_cursor#23 line_cursor#45 line_cursor#1 line_cursor#10 mulf_tables_cmp::kc_sqr#2 mulf_tables_cmp::kc_sqr#1 mulf_init::sqr1_lo#2 mulf_init::sqr1_lo#1 mulf_init::sqr2_lo#2 mulf_init::sqr2_lo#1 print_cls::sc#2 print_cls::sc#1 ]
|
||||
zp ZP_WORD:6 [ print_str::str#16 print_str::str#18 print_str::str#0 mul8u::mb#2 mul8u::mb#0 mul8u::mb#1 mulf_init::sqr1_hi#2 mulf_init::sqr1_hi#1 mulf_init::sqr2_hi#2 mulf_init::sqr2_hi#1 ]
|
||||
zp ZP_WORD:8 [ print_sword::w#5 print_sword::w#4 print_sword::w#1 print_sword::w#2 print_sword::w#3 print_sword::w#0 print_word::w#6 print_word::w#3 print_word::w#4 print_word::w#5 print_word::w#11 print_word::w#12 print_word::w#13 mulf_tables_cmp::asm_sqr#2 mulf_tables_cmp::asm_sqr#1 mul8s_error::ms#0 mul8s_compare::ms#0 muls8s::return#2 muls8s::m#5 muls8s::return#0 muls8s::m#3 muls8s::m#1 muls8s::m#2 mul8u_error::ms#0 mul8u_compare::ms#0 muls8u::return#2 muls8u::return#0 muls8u::m#3 muls8u::m#1 mulf_init::sqr#3 mulf_init::sqr#4 mulf_init::sqr#1 mulf_init::sqr#2 ]
|
||||
reg byte x [ print_byte::b#5 print_byte::b#3 print_byte::b#4 print_byte::b#9 print_byte::b#1 print_byte::b#2 ]
|
||||
reg byte a [ print_char::ch#4 print_char::ch#2 print_char::ch#3 ]
|
||||
zp ZP_WORD:10 [ char_cursor#82 char_cursor#137 char_cursor#136 char_cursor#132 char_cursor#149 char_cursor#188 char_cursor#189 char_cursor#131 char_cursor#130 char_cursor#17 char_cursor#30 char_cursor#1 char_cursor#134 char_cursor#222 ]
|
||||
reg byte x [ print_sbyte::b#4 print_sbyte::b#3 print_sbyte::b#1 print_sbyte::b#2 print_sbyte::b#0 ]
|
||||
zp ZP_WORD:12 [ mul8s::m#4 mul8s::m#5 mul8s::m#1 mul8s::m#0 mul8s::m#2 mul8s::return#2 mul8s_compare::mn#0 mul8s_error::mn#0 mul8u::return#2 mul8u::res#2 mul8u::res#6 mul8u::res#1 mul8u::return#3 mul8u_compare::mn#0 mul8u_error::mn#0 ]
|
||||
reg byte a [ mul8u::b#2 mul8u::b#3 mul8u::b#1 ]
|
||||
reg byte x [ mul8u::a#3 mul8u::a#6 mul8u::a#8 mul8u::a#2 mul8u::a#0 ]
|
||||
zp ZP_WORD:14 [ mulf8s::m#4 mulf8s::m#5 mulf8s::m#1 mulf8s::m#0 mulf8s::m#2 mulf8s::return#2 mul8s_compare::mf#0 mul8s_error::mf#0 mulf8u::return#2 mulf8u::return#0 mulf8u::return#3 mul8u_compare::mf#0 mul8u_error::mf#0 ]
|
||||
reg byte a [ mulf8u::a#2 mulf8u::a#1 mulf8u::a#4 ]
|
||||
reg byte x [ mulf8u::b#2 mulf8u::b#1 mulf8u::b#4 ]
|
||||
reg byte y [ muls8s::i#2 muls8s::i#1 ]
|
||||
reg byte y [ muls8s::j#2 muls8s::j#1 ]
|
||||
reg byte x [ mul8u_compare::ok#3 mul8u_compare::ok#4 ]
|
||||
reg byte y [ muls8u::i#2 muls8u::i#1 ]
|
||||
reg byte x [ mulf_init::c#2 mulf_init::c#1 ]
|
||||
reg byte x [ mulf_init::x_255#2 mulf_init::x_255#1 ]
|
||||
reg byte x [ muls8s::b#0 ]
|
||||
reg byte y [ mulf8s::a#0 ]
|
||||
reg byte y [ mul8s::b#0 ]
|
||||
reg byte x [ mul8s_error::a#0 ]
|
||||
reg byte a [ print_byte::$0 ]
|
||||
reg byte a [ print_byte::$2 ]
|
||||
reg byte a [ mul8s::$6 ]
|
||||
reg byte a [ mul8s::$16 ]
|
||||
reg byte a [ mul8s::$12 ]
|
||||
reg byte a [ mul8s::$17 ]
|
||||
reg byte a [ mul8u::$1 ]
|
||||
reg byte a [ mulf8s::$6 ]
|
||||
reg byte a [ mulf8s::$16 ]
|
||||
reg byte a [ mulf8s::$12 ]
|
||||
reg byte a [ mulf8s::$17 ]
|
||||
reg byte x [ muls8u::b#0 ]
|
||||
reg byte x [ mul8u_error::a#0 ]
|
||||
reg byte a [ mulf_init::$2 ]
|
||||
reg byte a [ mulf_init::$5 ]
|
||||
reg byte a [ mulf_init::$6 ]
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -1,728 +0,0 @@
|
||||
(label) @32
|
||||
(label) @begin
|
||||
(label) @end
|
||||
(byte*) BGCOL
|
||||
(const byte*) BGCOL#0 BGCOL = ((byte*))(word/dword/signed dword) 53281
|
||||
(byte*) SCREEN
|
||||
(const byte*) SCREEN#0 SCREEN = ((byte*))(word/signed word/dword/signed dword) 1024
|
||||
(byte*) char_cursor
|
||||
(byte*) char_cursor#1 char_cursor zp ZP_WORD:14 11.0
|
||||
(byte*) char_cursor#102 char_cursor zp ZP_WORD:14 1.253968253968253
|
||||
(byte*) char_cursor#124 char_cursor zp ZP_WORD:14 7.0
|
||||
(byte*) char_cursor#125 char_cursor zp ZP_WORD:14 0.8181818181818177
|
||||
(byte*) char_cursor#138 char_cursor zp ZP_WORD:14 0.1951219512195122
|
||||
(byte*) char_cursor#203 char_cursor zp ZP_WORD:14 7.25
|
||||
(byte*) char_cursor#204 char_cursor zp ZP_WORD:14 3.0
|
||||
(byte*) char_cursor#206 char_cursor zp ZP_WORD:14 3.0
|
||||
(byte*) char_cursor#208 char_cursor zp ZP_WORD:14 11.0
|
||||
(byte*) char_cursor#209 char_cursor zp ZP_WORD:14 4.0
|
||||
(byte*) char_cursor#210 char_cursor zp ZP_WORD:14 3.0
|
||||
(byte*) char_cursor#212 char_cursor zp ZP_WORD:14 3.9999999999999996
|
||||
(byte*) char_cursor#230 char_cursor zp ZP_WORD:14 48.0
|
||||
(byte*~) char_cursor#292 char_cursor zp ZP_WORD:14 4.0
|
||||
(byte*~) char_cursor#293 char_cursor zp ZP_WORD:14 4.0
|
||||
(byte*~) char_cursor#297 char_cursor zp ZP_WORD:14 4.0
|
||||
(byte*~) char_cursor#298 char_cursor zp ZP_WORD:14 4.0
|
||||
(byte*~) char_cursor#302 char_cursor zp ZP_WORD:14 4.0
|
||||
(byte*~) char_cursor#303 char_cursor zp ZP_WORD:14 4.0
|
||||
(byte*~) char_cursor#346 char_cursor zp ZP_WORD:14 4.0
|
||||
(byte*) line_cursor
|
||||
(byte*) line_cursor#1 line_cursor zp ZP_WORD:6 0.33701657458563516
|
||||
(byte*) line_cursor#12 line_cursor zp ZP_WORD:6 0.09523809523809523
|
||||
(byte*) line_cursor#35 line_cursor zp ZP_WORD:6 24.0
|
||||
(byte*) line_cursor#69 line_cursor zp ZP_WORD:6 18.0
|
||||
(void()) main()
|
||||
(label) main::@1
|
||||
(label) main::@2
|
||||
(label) main::@3
|
||||
(label) main::@4
|
||||
(label) main::@5
|
||||
(label) main::@6
|
||||
(label) main::@7
|
||||
(label) main::@return
|
||||
(signed dword()) mul16s((signed word) mul16s::a , (signed word) mul16s::b)
|
||||
(word~) mul16s::$12 $12 zp ZP_WORD:8 4.0
|
||||
(word~) mul16s::$16 $16 zp ZP_WORD:8 4.0
|
||||
(word~) mul16s::$17 $17 zp ZP_WORD:8 4.0
|
||||
(word~) mul16s::$6 $6 zp ZP_WORD:8 4.0
|
||||
(label) mul16s::@1
|
||||
(label) mul16s::@2
|
||||
(label) mul16s::@3
|
||||
(label) mul16s::@4
|
||||
(label) mul16s::@6
|
||||
(label) mul16s::@return
|
||||
(signed word) mul16s::a
|
||||
(signed word) mul16s::a#0 a zp ZP_WORD:2 7.357142857142858
|
||||
(signed word) mul16s::b
|
||||
(signed word) mul16s::b#0 b zp ZP_WORD:4 9.363636363636363
|
||||
(dword) mul16s::m
|
||||
(dword) mul16s::m#0 m zp ZP_DWORD:16 2.0
|
||||
(dword) mul16s::m#1 m zp ZP_DWORD:16 4.0
|
||||
(dword) mul16s::m#2 m zp ZP_DWORD:16 4.0
|
||||
(dword) mul16s::m#4 m zp ZP_DWORD:16 6.0
|
||||
(dword) mul16s::m#5 m zp ZP_DWORD:16 2.5
|
||||
(signed dword) mul16s::return
|
||||
(signed dword) mul16s::return#0 return zp ZP_DWORD:16 34.33333333333333
|
||||
(signed dword) mul16s::return#2 return zp ZP_DWORD:16 202.0
|
||||
(void()) mul16s_compare()
|
||||
(label) mul16s_compare::@1
|
||||
(label) mul16s_compare::@10
|
||||
(label) mul16s_compare::@11
|
||||
(label) mul16s_compare::@13
|
||||
(label) mul16s_compare::@2
|
||||
(label) mul16s_compare::@3
|
||||
(label) mul16s_compare::@4
|
||||
(label) mul16s_compare::@5
|
||||
(label) mul16s_compare::@6
|
||||
(label) mul16s_compare::@8
|
||||
(label) mul16s_compare::@9
|
||||
(label) mul16s_compare::@return
|
||||
(signed word) mul16s_compare::a
|
||||
(signed word) mul16s_compare::a#1 a zp ZP_WORD:2 19.857142857142858
|
||||
(signed word) mul16s_compare::a#2 a zp ZP_WORD:2 213.0
|
||||
(signed word) mul16s_compare::a#5 a zp ZP_WORD:2 22.0
|
||||
(signed word) mul16s_compare::b
|
||||
(signed word) mul16s_compare::b#1 b zp ZP_WORD:4 19.857142857142858
|
||||
(signed word) mul16s_compare::b#2 b zp ZP_WORD:4 106.5
|
||||
(signed word) mul16s_compare::b#5 b zp ZP_WORD:4 22.0
|
||||
(byte) mul16s_compare::i
|
||||
(byte) mul16s_compare::i#1 reg byte x 16.5
|
||||
(byte) mul16s_compare::i#9 reg byte x 1.1
|
||||
(byte) mul16s_compare::j
|
||||
(byte) mul16s_compare::j#1 reg byte y 151.5
|
||||
(byte) mul16s_compare::j#2 reg byte y 11.882352941176471
|
||||
(signed dword) mul16s_compare::mn
|
||||
(signed dword) mul16s_compare::mn#0 mn zp ZP_DWORD:16 22.666666666666664
|
||||
(signed dword) mul16s_compare::ms
|
||||
(signed dword) mul16s_compare::ms#0 ms zp ZP_DWORD:10 15.692307692307692
|
||||
(byte) mul16s_compare::ok
|
||||
(byte) mul16s_compare::ok#2 reg byte a 101.0
|
||||
(const string) mul16s_compare::str str = (string) "signed word multiply results match!@"
|
||||
(void()) mul16s_error((signed word) mul16s_error::a , (signed word) mul16s_error::b , (signed dword) mul16s_error::ms , (signed dword) mul16s_error::mn)
|
||||
(label) mul16s_error::@1
|
||||
(label) mul16s_error::@2
|
||||
(label) mul16s_error::@3
|
||||
(label) mul16s_error::@4
|
||||
(label) mul16s_error::@5
|
||||
(label) mul16s_error::@6
|
||||
(label) mul16s_error::@7
|
||||
(label) mul16s_error::@8
|
||||
(label) mul16s_error::@return
|
||||
(signed word) mul16s_error::a
|
||||
(signed word) mul16s_error::a#0 a zp ZP_WORD:2 0.6666666666666666
|
||||
(signed word) mul16s_error::b
|
||||
(signed word) mul16s_error::b#0 b zp ZP_WORD:4 0.4444444444444444
|
||||
(signed dword) mul16s_error::mn
|
||||
(signed dword) mul16s_error::mn#0 mn zp ZP_DWORD:16 0.26666666666666666
|
||||
(signed dword) mul16s_error::ms
|
||||
(signed dword) mul16s_error::ms#0 ms zp ZP_DWORD:10 0.3333333333333333
|
||||
(const string) mul16s_error::str str = (string) "signed word multiply mismatch @"
|
||||
(const string) mul16s_error::str1 str1 = (string) "*@"
|
||||
(const string) mul16s_error::str2 str2 = (string) " slow:@"
|
||||
(const string) mul16s_error::str3 str3 = (string) " / normal:@"
|
||||
(dword()) mul16u((word) mul16u::a , (word) mul16u::b)
|
||||
(byte~) mul16u::$1 reg byte a 2002.0
|
||||
(label) mul16u::@1
|
||||
(label) mul16u::@2
|
||||
(label) mul16u::@4
|
||||
(label) mul16u::@7
|
||||
(label) mul16u::@return
|
||||
(word) mul16u::a
|
||||
(word) mul16u::a#0 a zp ZP_WORD:8 1001.0
|
||||
(word) mul16u::a#2 a zp ZP_WORD:8 101.0
|
||||
(word) mul16u::a#3 a zp ZP_WORD:8 667.6666666666667
|
||||
(word) mul16u::a#6 a zp ZP_WORD:8 52.5
|
||||
(word~) mul16u::a#8 a zp ZP_WORD:8 4.0
|
||||
(word) mul16u::b
|
||||
(word) mul16u::b#1 b zp ZP_WORD:20 202.0
|
||||
(word) mul16u::b#2 b zp ZP_WORD:20 105.0
|
||||
(word~) mul16u::b#3 b zp ZP_WORD:20 2.0
|
||||
(dword) mul16u::mb
|
||||
(dword) mul16u::mb#0 mb zp ZP_DWORD:22 4.0
|
||||
(dword) mul16u::mb#1 mb zp ZP_DWORD:22 2002.0
|
||||
(dword) mul16u::mb#2 mb zp ZP_DWORD:22 429.2857142857143
|
||||
(dword) mul16u::res
|
||||
(dword) mul16u::res#1 res zp ZP_DWORD:16 2002.0
|
||||
(dword) mul16u::res#2 res zp ZP_DWORD:16 443.7142857142857
|
||||
(dword) mul16u::res#6 res zp ZP_DWORD:16 1001.0
|
||||
(dword) mul16u::return
|
||||
(dword) mul16u::return#2 return zp ZP_DWORD:16 4.0
|
||||
(dword) mul16u::return#3 return zp ZP_DWORD:16 202.0
|
||||
(void()) mul16u_compare()
|
||||
(label) mul16u_compare::@1
|
||||
(label) mul16u_compare::@10
|
||||
(label) mul16u_compare::@11
|
||||
(label) mul16u_compare::@13
|
||||
(label) mul16u_compare::@2
|
||||
(label) mul16u_compare::@3
|
||||
(label) mul16u_compare::@4
|
||||
(label) mul16u_compare::@5
|
||||
(label) mul16u_compare::@6
|
||||
(label) mul16u_compare::@8
|
||||
(label) mul16u_compare::@9
|
||||
(label) mul16u_compare::@return
|
||||
(word) mul16u_compare::a
|
||||
(word) mul16u_compare::a#1 a zp ZP_WORD:2 19.857142857142858
|
||||
(word) mul16u_compare::a#2 a zp ZP_WORD:2 213.0
|
||||
(word) mul16u_compare::a#5 a zp ZP_WORD:2 22.0
|
||||
(word) mul16u_compare::b
|
||||
(word) mul16u_compare::b#1 b zp ZP_WORD:20 19.857142857142858
|
||||
(word) mul16u_compare::b#2 b zp ZP_WORD:20 106.5
|
||||
(word) mul16u_compare::b#5 b zp ZP_WORD:20 22.0
|
||||
(byte) mul16u_compare::i
|
||||
(byte) mul16u_compare::i#1 reg byte x 16.5
|
||||
(byte) mul16u_compare::i#9 reg byte x 1.1
|
||||
(byte) mul16u_compare::j
|
||||
(byte) mul16u_compare::j#1 reg byte y 151.5
|
||||
(byte) mul16u_compare::j#2 reg byte y 11.882352941176471
|
||||
(dword) mul16u_compare::mn
|
||||
(dword) mul16u_compare::mn#0 mn zp ZP_DWORD:16 22.666666666666664
|
||||
(dword) mul16u_compare::ms
|
||||
(dword) mul16u_compare::ms#0 ms zp ZP_DWORD:10 15.692307692307692
|
||||
(byte) mul16u_compare::ok
|
||||
(byte) mul16u_compare::ok#2 reg byte a 101.0
|
||||
(const string) mul16u_compare::str str = (string) "word multiply results match!@"
|
||||
(void()) mul16u_error((word) mul16u_error::a , (word) mul16u_error::b , (dword) mul16u_error::ms , (dword) mul16u_error::mn)
|
||||
(label) mul16u_error::@1
|
||||
(label) mul16u_error::@2
|
||||
(label) mul16u_error::@3
|
||||
(label) mul16u_error::@4
|
||||
(label) mul16u_error::@5
|
||||
(label) mul16u_error::@6
|
||||
(label) mul16u_error::@7
|
||||
(label) mul16u_error::@8
|
||||
(label) mul16u_error::@return
|
||||
(word) mul16u_error::a
|
||||
(word) mul16u_error::a#0 a zp ZP_WORD:2 0.6666666666666666
|
||||
(word) mul16u_error::b
|
||||
(word) mul16u_error::b#0 b zp ZP_WORD:20 0.4444444444444444
|
||||
(dword) mul16u_error::mn
|
||||
(dword) mul16u_error::mn#0 mn zp ZP_DWORD:16 0.26666666666666666
|
||||
(dword) mul16u_error::ms
|
||||
(dword) mul16u_error::ms#0 ms zp ZP_DWORD:10 0.3333333333333333
|
||||
(const string) mul16u_error::str str = (string) "word multiply mismatch @"
|
||||
(const string) mul16u_error::str1 str1 = (string) "*@"
|
||||
(const string) mul16u_error::str2 str2 = (string) " slow:@"
|
||||
(const string) mul16u_error::str3 str3 = (string) " / normal:@"
|
||||
(signed word()) mul8s((signed byte) mul8s::a , (signed byte) mul8s::b)
|
||||
(byte~) mul8s::$12 reg byte a 4.0
|
||||
(byte/signed byte/word/signed word/dword/signed dword~) mul8s::$16 reg byte a 4.0
|
||||
(byte/signed byte/word/signed word/dword/signed dword~) mul8s::$17 reg byte a 4.0
|
||||
(byte~) mul8s::$6 reg byte a 4.0
|
||||
(label) mul8s::@1
|
||||
(label) mul8s::@2
|
||||
(label) mul8s::@3
|
||||
(label) mul8s::@4
|
||||
(label) mul8s::@6
|
||||
(label) mul8s::@return
|
||||
(signed byte) mul8s::a
|
||||
(signed byte) mul8s::a#0 a zp ZP_BYTE:26 7.357142857142858
|
||||
(signed byte) mul8s::b
|
||||
(signed byte) mul8s::b#0 reg byte y 9.363636363636363
|
||||
(word) mul8s::m
|
||||
(word) mul8s::m#0 m zp ZP_WORD:4 2.0
|
||||
(word) mul8s::m#1 m zp ZP_WORD:4 4.0
|
||||
(word) mul8s::m#2 m zp ZP_WORD:4 4.0
|
||||
(word) mul8s::m#4 m zp ZP_WORD:4 1.3333333333333333
|
||||
(word) mul8s::m#5 m zp ZP_WORD:4 2.5
|
||||
(signed word) mul8s::return
|
||||
(signed word) mul8s::return#2 return zp ZP_WORD:4 202.0
|
||||
(void()) mul8s_compare()
|
||||
(label) mul8s_compare::@1
|
||||
(label) mul8s_compare::@10
|
||||
(label) mul8s_compare::@11
|
||||
(label) mul8s_compare::@12
|
||||
(label) mul8s_compare::@13
|
||||
(label) mul8s_compare::@14
|
||||
(label) mul8s_compare::@16
|
||||
(label) mul8s_compare::@2
|
||||
(label) mul8s_compare::@20
|
||||
(label) mul8s_compare::@3
|
||||
(label) mul8s_compare::@4
|
||||
(label) mul8s_compare::@5
|
||||
(label) mul8s_compare::@6
|
||||
(label) mul8s_compare::@8
|
||||
(label) mul8s_compare::@return
|
||||
(signed byte) mul8s_compare::a
|
||||
(signed byte) mul8s_compare::a#1 a zp ZP_BYTE:26 16.5
|
||||
(signed byte) mul8s_compare::a#7 a zp ZP_BYTE:26 12.11111111111111
|
||||
(signed byte) mul8s_compare::b
|
||||
(signed byte) mul8s_compare::b#1 b zp ZP_BYTE:27 151.5
|
||||
(signed byte) mul8s_compare::b#10 b zp ZP_BYTE:27 20.279999999999998
|
||||
(signed word) mul8s_compare::mf
|
||||
(signed word) mul8s_compare::mf#0 mf zp ZP_WORD:20 11.333333333333332
|
||||
(signed word) mul8s_compare::mn
|
||||
(signed word) mul8s_compare::mn#0 mn zp ZP_WORD:4 17.0
|
||||
(signed word) mul8s_compare::ms
|
||||
(signed word) mul8s_compare::ms#0 ms zp ZP_WORD:2 14.523809523809522
|
||||
(byte) mul8s_compare::ok
|
||||
(byte) mul8s_compare::ok#3 reg byte x 202.0
|
||||
(byte) mul8s_compare::ok#4 reg byte x 33.666666666666664
|
||||
(const string) mul8s_compare::str str = (string) "signed multiply results match!@"
|
||||
(void()) mul8s_error((signed byte) mul8s_error::a , (signed byte) mul8s_error::b , (signed word) mul8s_error::ms , (signed word) mul8s_error::mn , (signed word) mul8s_error::mf)
|
||||
(label) mul8s_error::@1
|
||||
(label) mul8s_error::@10
|
||||
(label) mul8s_error::@2
|
||||
(label) mul8s_error::@3
|
||||
(label) mul8s_error::@4
|
||||
(label) mul8s_error::@5
|
||||
(label) mul8s_error::@6
|
||||
(label) mul8s_error::@7
|
||||
(label) mul8s_error::@8
|
||||
(label) mul8s_error::@9
|
||||
(label) mul8s_error::@return
|
||||
(signed byte) mul8s_error::a
|
||||
(signed byte) mul8s_error::a#0 reg byte x 0.5714285714285714
|
||||
(signed byte) mul8s_error::b
|
||||
(signed byte) mul8s_error::b#0 b zp ZP_BYTE:27 0.4
|
||||
(signed word) mul8s_error::mf
|
||||
(signed word) mul8s_error::mf#0 mf zp ZP_WORD:20 0.21052631578947367
|
||||
(signed word) mul8s_error::mn
|
||||
(signed word) mul8s_error::mn#0 mn zp ZP_WORD:4 0.25
|
||||
(signed word) mul8s_error::ms
|
||||
(signed word) mul8s_error::ms#0 ms zp ZP_WORD:2 0.3076923076923077
|
||||
(const string) mul8s_error::str str = (string) "signed multiply mismatch @"
|
||||
(const string) mul8s_error::str1 str1 = (string) "*@"
|
||||
(const string) mul8s_error::str2 str2 = (string) " slow:@"
|
||||
(const string) mul8s_error::str3 str3 = (string) " / normal:@"
|
||||
(const string) mul8s_error::str4 str4 = (string) " / fast:@"
|
||||
(word()) mul8u((byte) mul8u::a , (byte) mul8u::b)
|
||||
(byte~) mul8u::$1 reg byte a 2002.0
|
||||
(label) mul8u::@1
|
||||
(label) mul8u::@2
|
||||
(label) mul8u::@4
|
||||
(label) mul8u::@7
|
||||
(label) mul8u::@return
|
||||
(byte) mul8u::a
|
||||
(byte) mul8u::a#0 reg byte x 1001.0
|
||||
(byte) mul8u::a#2 reg byte x 101.0
|
||||
(byte) mul8u::a#3 reg byte x 667.6666666666667
|
||||
(byte) mul8u::a#6 reg byte x 52.5
|
||||
(byte~) mul8u::a#8 reg byte x 4.0
|
||||
(byte) mul8u::b
|
||||
(byte) mul8u::b#1 reg byte a 202.0
|
||||
(byte) mul8u::b#2 reg byte a 105.0
|
||||
(byte~) mul8u::b#3 reg byte a 2.0
|
||||
(word) mul8u::mb
|
||||
(word) mul8u::mb#0 mb zp ZP_WORD:8 4.0
|
||||
(word) mul8u::mb#1 mb zp ZP_WORD:8 2002.0
|
||||
(word) mul8u::mb#2 mb zp ZP_WORD:8 429.2857142857143
|
||||
(word) mul8u::res
|
||||
(word) mul8u::res#1 res zp ZP_WORD:4 2002.0
|
||||
(word) mul8u::res#2 res zp ZP_WORD:4 443.7142857142857
|
||||
(word) mul8u::res#6 res zp ZP_WORD:4 1001.0
|
||||
(word) mul8u::return
|
||||
(word) mul8u::return#2 return zp ZP_WORD:4 4.0
|
||||
(word) mul8u::return#3 return zp ZP_WORD:4 202.0
|
||||
(void()) mul8u_compare()
|
||||
(label) mul8u_compare::@1
|
||||
(label) mul8u_compare::@10
|
||||
(label) mul8u_compare::@11
|
||||
(label) mul8u_compare::@12
|
||||
(label) mul8u_compare::@13
|
||||
(label) mul8u_compare::@14
|
||||
(label) mul8u_compare::@16
|
||||
(label) mul8u_compare::@2
|
||||
(label) mul8u_compare::@20
|
||||
(label) mul8u_compare::@3
|
||||
(label) mul8u_compare::@4
|
||||
(label) mul8u_compare::@5
|
||||
(label) mul8u_compare::@6
|
||||
(label) mul8u_compare::@8
|
||||
(label) mul8u_compare::@return
|
||||
(byte) mul8u_compare::a
|
||||
(byte) mul8u_compare::a#1 a zp ZP_BYTE:26 16.5
|
||||
(byte) mul8u_compare::a#7 a zp ZP_BYTE:26 12.11111111111111
|
||||
(byte) mul8u_compare::b
|
||||
(byte) mul8u_compare::b#1 b zp ZP_BYTE:27 151.5
|
||||
(byte) mul8u_compare::b#10 b zp ZP_BYTE:27 20.279999999999998
|
||||
(word) mul8u_compare::mf
|
||||
(word) mul8u_compare::mf#0 mf zp ZP_WORD:20 11.333333333333332
|
||||
(word) mul8u_compare::mn
|
||||
(word) mul8u_compare::mn#0 mn zp ZP_WORD:4 17.0
|
||||
(word) mul8u_compare::ms
|
||||
(word) mul8u_compare::ms#0 ms zp ZP_WORD:2 14.523809523809522
|
||||
(byte) mul8u_compare::ok
|
||||
(byte) mul8u_compare::ok#3 reg byte x 202.0
|
||||
(byte) mul8u_compare::ok#4 reg byte x 33.666666666666664
|
||||
(const string) mul8u_compare::str str = (string) "multiply results match!@"
|
||||
(void()) mul8u_error((byte) mul8u_error::a , (byte) mul8u_error::b , (word) mul8u_error::ms , (word) mul8u_error::mn , (word) mul8u_error::mf)
|
||||
(label) mul8u_error::@1
|
||||
(label) mul8u_error::@10
|
||||
(label) mul8u_error::@2
|
||||
(label) mul8u_error::@3
|
||||
(label) mul8u_error::@4
|
||||
(label) mul8u_error::@5
|
||||
(label) mul8u_error::@6
|
||||
(label) mul8u_error::@7
|
||||
(label) mul8u_error::@8
|
||||
(label) mul8u_error::@9
|
||||
(label) mul8u_error::@return
|
||||
(byte) mul8u_error::a
|
||||
(byte) mul8u_error::a#0 reg byte x 0.5714285714285714
|
||||
(byte) mul8u_error::b
|
||||
(byte) mul8u_error::b#0 b zp ZP_BYTE:27 0.4
|
||||
(word) mul8u_error::mf
|
||||
(word) mul8u_error::mf#0 mf zp ZP_WORD:20 0.21052631578947367
|
||||
(word) mul8u_error::mn
|
||||
(word) mul8u_error::mn#0 mn zp ZP_WORD:4 0.25
|
||||
(word) mul8u_error::ms
|
||||
(word) mul8u_error::ms#0 ms zp ZP_WORD:2 0.3076923076923077
|
||||
(const string) mul8u_error::str str = (string) "multiply mismatch @"
|
||||
(const string) mul8u_error::str1 str1 = (string) "*@"
|
||||
(const string) mul8u_error::str2 str2 = (string) " slow:@"
|
||||
(const string) mul8u_error::str3 str3 = (string) " / normal:@"
|
||||
(const string) mul8u_error::str4 str4 = (string) " / fast:@"
|
||||
(byte[512]) mula_sqr1_hi
|
||||
(const byte[512]) mula_sqr1_hi#0 mula_sqr1_hi = { fill( 512, 0) }
|
||||
(byte[512]) mula_sqr1_lo
|
||||
(const byte[512]) mula_sqr1_lo#0 mula_sqr1_lo = { fill( 512, 0) }
|
||||
(byte[512]) mula_sqr2_hi
|
||||
(const byte[512]) mula_sqr2_hi#0 mula_sqr2_hi = { fill( 512, 0) }
|
||||
(byte[512]) mula_sqr2_lo
|
||||
(const byte[512]) mula_sqr2_lo#0 mula_sqr2_lo = { fill( 512, 0) }
|
||||
(signed word()) mulf8s((signed byte) mulf8s::a , (signed byte) mulf8s::b)
|
||||
(byte~) mulf8s::$12 reg byte a 4.0
|
||||
(byte/signed byte/word/signed word/dword/signed dword~) mulf8s::$16 reg byte a 4.0
|
||||
(byte/signed byte/word/signed word/dword/signed dword~) mulf8s::$17 reg byte a 4.0
|
||||
(byte~) mulf8s::$6 reg byte a 4.0
|
||||
(label) mulf8s::@1
|
||||
(label) mulf8s::@2
|
||||
(label) mulf8s::@3
|
||||
(label) mulf8s::@4
|
||||
(label) mulf8s::@6
|
||||
(label) mulf8s::@return
|
||||
(signed byte) mulf8s::a
|
||||
(signed byte) mulf8s::a#0 reg byte y 7.357142857142858
|
||||
(signed byte) mulf8s::b
|
||||
(signed byte) mulf8s::b#0 b zp ZP_BYTE:27 9.363636363636363
|
||||
(word) mulf8s::m
|
||||
(word) mulf8s::m#0 m zp ZP_WORD:20 2.0
|
||||
(word) mulf8s::m#1 m zp ZP_WORD:20 4.0
|
||||
(word) mulf8s::m#2 m zp ZP_WORD:20 4.0
|
||||
(word) mulf8s::m#4 m zp ZP_WORD:20 1.3333333333333333
|
||||
(word) mulf8s::m#5 m zp ZP_WORD:20 2.5
|
||||
(signed word) mulf8s::return
|
||||
(signed word) mulf8s::return#2 return zp ZP_WORD:20 202.0
|
||||
(word()) mulf8u((byte) mulf8u::a , (byte) mulf8u::b)
|
||||
(label) mulf8u::@return
|
||||
(byte) mulf8u::a
|
||||
(byte) mulf8u::a#1 reg byte a 101.0
|
||||
(byte) mulf8u::a#2 reg byte a 105.0
|
||||
(byte~) mulf8u::a#4 reg byte a 2.0
|
||||
(byte) mulf8u::b
|
||||
(byte) mulf8u::b#1 reg byte x 202.0
|
||||
(byte) mulf8u::b#2 reg byte x 52.5
|
||||
(byte~) mulf8u::b#4 reg byte x 4.0
|
||||
(byte*) mulf8u::memA
|
||||
(const byte*) mulf8u::memA#0 memA = ((byte*))(byte/word/signed word/dword/signed dword) 254
|
||||
(byte*) mulf8u::memB
|
||||
(const byte*) mulf8u::memB#0 memB = ((byte*))(byte/word/signed word/dword/signed dword) 255
|
||||
(word) mulf8u::return
|
||||
(word) mulf8u::return#0 return zp ZP_WORD:20 26.25
|
||||
(word) mulf8u::return#2 return zp ZP_WORD:20 4.0
|
||||
(word) mulf8u::return#3 return zp ZP_WORD:20 202.0
|
||||
(void()) mulf_init()
|
||||
(byte~) mulf_init::$2 reg byte a 22.0
|
||||
(byte~) mulf_init::$5 reg byte a 22.0
|
||||
(byte~) mulf_init::$6 reg byte a 22.0
|
||||
(label) mulf_init::@1
|
||||
(label) mulf_init::@12
|
||||
(label) mulf_init::@2
|
||||
(label) mulf_init::@3
|
||||
(label) mulf_init::@4
|
||||
(label) mulf_init::@5
|
||||
(label) mulf_init::@8
|
||||
(label) mulf_init::@return
|
||||
(byte) mulf_init::c
|
||||
(byte) mulf_init::c#1 reg byte x 2.357142857142857
|
||||
(byte) mulf_init::c#2 reg byte x 22.0
|
||||
(byte) mulf_init::dir
|
||||
(byte) mulf_init::dir#2 dir zp ZP_BYTE:26 4.714285714285714
|
||||
(byte) mulf_init::dir#3 dir zp ZP_BYTE:26 7.333333333333333
|
||||
(word) mulf_init::sqr
|
||||
(word) mulf_init::sqr#1 sqr zp ZP_WORD:6 7.333333333333333
|
||||
(word) mulf_init::sqr#2 sqr zp ZP_WORD:6 22.0
|
||||
(word) mulf_init::sqr#3 sqr zp ZP_WORD:6 9.166666666666666
|
||||
(word) mulf_init::sqr#4 sqr zp ZP_WORD:6 6.6000000000000005
|
||||
(byte*) mulf_init::sqr1_hi
|
||||
(byte*) mulf_init::sqr1_hi#1 sqr1_hi zp ZP_WORD:4 5.5
|
||||
(byte*) mulf_init::sqr1_hi#2 sqr1_hi zp ZP_WORD:4 3.0
|
||||
(byte*) mulf_init::sqr1_lo
|
||||
(byte*) mulf_init::sqr1_lo#1 sqr1_lo zp ZP_WORD:2 16.5
|
||||
(byte*) mulf_init::sqr1_lo#2 sqr1_lo zp ZP_WORD:2 2.5384615384615383
|
||||
(byte*) mulf_init::sqr2_hi
|
||||
(byte*) mulf_init::sqr2_hi#1 sqr2_hi zp ZP_WORD:4 3.142857142857143
|
||||
(byte*) mulf_init::sqr2_hi#2 sqr2_hi zp ZP_WORD:4 11.0
|
||||
(byte*) mulf_init::sqr2_lo
|
||||
(byte*) mulf_init::sqr2_lo#1 sqr2_lo zp ZP_WORD:2 16.5
|
||||
(byte*) mulf_init::sqr2_lo#2 sqr2_lo zp ZP_WORD:2 4.125
|
||||
(byte) mulf_init::x_2
|
||||
(byte) mulf_init::x_2#1 x_2 zp ZP_BYTE:26 11.0
|
||||
(byte) mulf_init::x_2#2 x_2 zp ZP_BYTE:26 4.888888888888889
|
||||
(byte) mulf_init::x_2#3 x_2 zp ZP_BYTE:26 8.25
|
||||
(byte) mulf_init::x_255
|
||||
(byte) mulf_init::x_255#1 reg byte x 5.5
|
||||
(byte) mulf_init::x_255#2 reg byte x 11.0
|
||||
(void()) mulf_init_asm()
|
||||
(label) mulf_init_asm::@return
|
||||
(byte*) mulf_init_asm::mem
|
||||
(const byte*) mulf_init_asm::mem#0 mem = ((byte*))(byte/word/signed word/dword/signed dword) 255
|
||||
(byte[512]) mulf_sqr1_hi
|
||||
(const byte[512]) mulf_sqr1_hi#0 mulf_sqr1_hi = { fill( 512, 0) }
|
||||
(byte[512]) mulf_sqr1_lo
|
||||
(const byte[512]) mulf_sqr1_lo#0 mulf_sqr1_lo = { fill( 512, 0) }
|
||||
(byte[512]) mulf_sqr2_hi
|
||||
(const byte[512]) mulf_sqr2_hi#0 mulf_sqr2_hi = { fill( 512, 0) }
|
||||
(byte[512]) mulf_sqr2_lo
|
||||
(const byte[512]) mulf_sqr2_lo#0 mulf_sqr2_lo = { fill( 512, 0) }
|
||||
(void()) mulf_tables_cmp()
|
||||
(label) mulf_tables_cmp::@1
|
||||
(label) mulf_tables_cmp::@10
|
||||
(label) mulf_tables_cmp::@2
|
||||
(label) mulf_tables_cmp::@3
|
||||
(label) mulf_tables_cmp::@5
|
||||
(label) mulf_tables_cmp::@6
|
||||
(label) mulf_tables_cmp::@7
|
||||
(label) mulf_tables_cmp::@8
|
||||
(label) mulf_tables_cmp::@return
|
||||
(byte*) mulf_tables_cmp::asm_sqr
|
||||
(byte*) mulf_tables_cmp::asm_sqr#1 asm_sqr zp ZP_WORD:2 7.333333333333333
|
||||
(byte*) mulf_tables_cmp::asm_sqr#2 asm_sqr zp ZP_WORD:2 8.25
|
||||
(byte*) mulf_tables_cmp::kc_sqr
|
||||
(byte*) mulf_tables_cmp::kc_sqr#1 kc_sqr zp ZP_WORD:4 16.5
|
||||
(byte*) mulf_tables_cmp::kc_sqr#2 kc_sqr zp ZP_WORD:4 3.666666666666667
|
||||
(const string) mulf_tables_cmp::str str = (string) "multiply table mismatch at @"
|
||||
(const string) mulf_tables_cmp::str1 str1 = (string) " / @"
|
||||
(const string) mulf_tables_cmp::str2 str2 = (string) "multiply tables match!@"
|
||||
(signed dword()) muls16s((signed word) muls16s::a , (signed word) muls16s::b)
|
||||
(label) muls16s::@1
|
||||
(label) muls16s::@2
|
||||
(label) muls16s::@3
|
||||
(label) muls16s::@5
|
||||
(label) muls16s::@return
|
||||
(signed word) muls16s::a
|
||||
(signed word) muls16s::a#0 a zp ZP_WORD:2 175.58333333333334
|
||||
(signed word) muls16s::b
|
||||
(signed word) muls16s::b#0 b zp ZP_WORD:4 191.1818181818182
|
||||
(signed word) muls16s::i
|
||||
(signed word) muls16s::i#1 i zp ZP_WORD:8 1501.5
|
||||
(signed word) muls16s::i#2 i zp ZP_WORD:8 1001.0
|
||||
(signed word) muls16s::j
|
||||
(signed word) muls16s::j#1 j zp ZP_WORD:8 1501.5
|
||||
(signed word) muls16s::j#2 j zp ZP_WORD:8 1001.0
|
||||
(signed dword) muls16s::m
|
||||
(signed dword) muls16s::m#1 m zp ZP_DWORD:10 1001.0
|
||||
(signed dword) muls16s::m#2 m zp ZP_DWORD:10 1001.0
|
||||
(signed dword) muls16s::m#3 m zp ZP_DWORD:10 2002.0
|
||||
(signed dword) muls16s::m#5 m zp ZP_DWORD:10 2002.0
|
||||
(signed dword) muls16s::return
|
||||
(signed dword) muls16s::return#0 return zp ZP_DWORD:10 701.0
|
||||
(signed dword) muls16s::return#2 return zp ZP_DWORD:10 202.0
|
||||
(dword()) muls16u((word) muls16u::a , (word) muls16u::b)
|
||||
(label) muls16u::@1
|
||||
(label) muls16u::@2
|
||||
(label) muls16u::@return
|
||||
(word) muls16u::a
|
||||
(word) muls16u::a#0 a zp ZP_WORD:2 157.71428571428572
|
||||
(word) muls16u::b
|
||||
(word) muls16u::b#0 b zp ZP_WORD:20 183.66666666666669
|
||||
(word) muls16u::i
|
||||
(word) muls16u::i#1 i zp ZP_WORD:4 1501.5
|
||||
(word) muls16u::i#2 i zp ZP_WORD:4 1001.0
|
||||
(dword) muls16u::m
|
||||
(dword) muls16u::m#1 m zp ZP_DWORD:10 1001.0
|
||||
(dword) muls16u::m#3 m zp ZP_DWORD:10 2002.0
|
||||
(dword) muls16u::return
|
||||
(dword) muls16u::return#0 return zp ZP_DWORD:10 367.33333333333337
|
||||
(dword) muls16u::return#2 return zp ZP_DWORD:10 202.0
|
||||
(signed word()) muls8s((signed byte) muls8s::a , (signed byte) muls8s::b)
|
||||
(label) muls8s::@1
|
||||
(label) muls8s::@2
|
||||
(label) muls8s::@3
|
||||
(label) muls8s::@5
|
||||
(label) muls8s::@return
|
||||
(signed byte) muls8s::a
|
||||
(signed byte) muls8s::a#0 a zp ZP_BYTE:26 175.58333333333334
|
||||
(signed byte) muls8s::b
|
||||
(signed byte) muls8s::b#0 reg byte x 191.1818181818182
|
||||
(signed byte) muls8s::i
|
||||
(signed byte) muls8s::i#1 reg byte y 1501.5
|
||||
(signed byte) muls8s::i#2 reg byte y 1001.0
|
||||
(signed byte) muls8s::j
|
||||
(signed byte) muls8s::j#1 reg byte y 1501.5
|
||||
(signed byte) muls8s::j#2 reg byte y 1001.0
|
||||
(signed word) muls8s::m
|
||||
(signed word) muls8s::m#1 m zp ZP_WORD:2 1001.0
|
||||
(signed word) muls8s::m#2 m zp ZP_WORD:2 1001.0
|
||||
(signed word) muls8s::m#3 m zp ZP_WORD:2 2002.0
|
||||
(signed word) muls8s::m#5 m zp ZP_WORD:2 2002.0
|
||||
(signed word) muls8s::return
|
||||
(signed word) muls8s::return#0 return zp ZP_WORD:2 701.0
|
||||
(signed word) muls8s::return#2 return zp ZP_WORD:2 202.0
|
||||
(word()) muls8u((byte) muls8u::a , (byte) muls8u::b)
|
||||
(label) muls8u::@1
|
||||
(label) muls8u::@2
|
||||
(label) muls8u::@return
|
||||
(byte) muls8u::a
|
||||
(byte) muls8u::a#0 a zp ZP_BYTE:26 157.71428571428572
|
||||
(byte) muls8u::b
|
||||
(byte) muls8u::b#0 reg byte x 183.66666666666669
|
||||
(byte) muls8u::i
|
||||
(byte) muls8u::i#1 reg byte y 1501.5
|
||||
(byte) muls8u::i#2 reg byte y 1001.0
|
||||
(word) muls8u::m
|
||||
(word) muls8u::m#1 m zp ZP_WORD:2 1001.0
|
||||
(word) muls8u::m#3 m zp ZP_WORD:2 2002.0
|
||||
(word) muls8u::return
|
||||
(word) muls8u::return#0 return zp ZP_WORD:2 367.33333333333337
|
||||
(word) muls8u::return#2 return zp ZP_WORD:2 202.0
|
||||
(void()) print_byte((byte) print_byte::b)
|
||||
(byte~) print_byte::$0 reg byte a 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#1 reg byte x 4.0
|
||||
(byte) print_byte::b#2 reg byte x 4.0
|
||||
(byte) print_byte::b#3 reg byte x 4.0
|
||||
(byte) print_byte::b#4 reg byte x 4.0
|
||||
(byte) print_byte::b#5 reg byte x 3.5
|
||||
(byte~) print_byte::b#9 reg byte x 4.0
|
||||
(byte[]) print_byte::hextab
|
||||
(const string) print_byte::hextab#0 hextab = (string) "0123456789abcdef"
|
||||
(void()) print_char((byte) print_char::ch)
|
||||
(label) print_char::@return
|
||||
(byte) print_char::ch
|
||||
(byte) print_char::ch#3 reg byte a 4.0
|
||||
(byte) print_char::ch#4 reg byte a 4.0
|
||||
(byte) print_char::ch#5 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:2 16.5
|
||||
(byte*) print_cls::sc#2 sc zp ZP_WORD:2 16.5
|
||||
(void()) print_dword((dword) print_dword::dw)
|
||||
(label) print_dword::@1
|
||||
(label) print_dword::@return
|
||||
(dword) print_dword::dw
|
||||
(dword) print_dword::dw#0 dw zp ZP_DWORD:10 4.0
|
||||
(dword) print_dword::dw#1 dw zp ZP_DWORD:10 4.0
|
||||
(dword) print_dword::dw#2 dw zp ZP_DWORD:10 4.0
|
||||
(dword) print_dword::dw#3 dw zp ZP_DWORD:10 3.333333333333333
|
||||
(void()) print_ln()
|
||||
(label) print_ln::@1
|
||||
(label) print_ln::@return
|
||||
(void()) print_sbyte((signed byte) print_sbyte::b)
|
||||
(label) print_sbyte::@1
|
||||
(label) print_sbyte::@2
|
||||
(label) print_sbyte::@4
|
||||
(label) print_sbyte::@return
|
||||
(signed byte) print_sbyte::b
|
||||
(signed byte) print_sbyte::b#0 reg byte x 4.0
|
||||
(signed byte) print_sbyte::b#1 reg byte x 4.0
|
||||
(signed byte) print_sbyte::b#2 reg byte x 4.0
|
||||
(signed byte) print_sbyte::b#3 reg byte x 2.5
|
||||
(signed byte) print_sbyte::b#4 reg byte x 4.0
|
||||
(void()) print_sdword((signed dword) print_sdword::dw)
|
||||
(label) print_sdword::@1
|
||||
(label) print_sdword::@2
|
||||
(label) print_sdword::@4
|
||||
(label) print_sdword::@return
|
||||
(signed dword) print_sdword::dw
|
||||
(signed dword) print_sdword::dw#0 dw zp ZP_DWORD:10 4.0
|
||||
(signed dword) print_sdword::dw#1 dw zp ZP_DWORD:10 4.0
|
||||
(signed dword) print_sdword::dw#2 dw zp ZP_DWORD:10 4.0
|
||||
(signed dword) print_sdword::dw#3 dw zp ZP_DWORD:10 2.5
|
||||
(signed dword) print_sdword::dw#4 dw zp ZP_DWORD:10 6.0
|
||||
(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#26 str zp ZP_WORD:8 11.5
|
||||
(byte*) print_str::str#28 str zp ZP_WORD:8 2.0
|
||||
(void()) print_sword((signed word) print_sword::w)
|
||||
(label) print_sword::@1
|
||||
(label) print_sword::@2
|
||||
(label) print_sword::@4
|
||||
(label) print_sword::@return
|
||||
(signed word) print_sword::w
|
||||
(signed word) print_sword::w#0 w zp ZP_WORD:2 4.0
|
||||
(signed word) print_sword::w#1 w zp ZP_WORD:2 4.0
|
||||
(signed word) print_sword::w#2 w zp ZP_WORD:2 4.0
|
||||
(signed word) print_sword::w#3 w zp ZP_WORD:2 4.0
|
||||
(signed word) print_sword::w#4 w zp ZP_WORD:2 4.0
|
||||
(signed word) print_sword::w#5 w zp ZP_WORD:2 4.0
|
||||
(signed word) print_sword::w#6 w zp ZP_WORD:2 4.0
|
||||
(signed word) print_sword::w#7 w zp ZP_WORD:2 4.0
|
||||
(void()) print_word((word) print_word::w)
|
||||
(label) print_word::@1
|
||||
(label) print_word::@return
|
||||
(word) print_word::w
|
||||
(word) print_word::w#1 w zp ZP_WORD:2 4.0
|
||||
(word) print_word::w#10 w zp ZP_WORD:2 8.0
|
||||
(word~) print_word::w#17 w zp ZP_WORD:2 4.0
|
||||
(word~) print_word::w#18 w zp ZP_WORD:2 4.0
|
||||
(word) print_word::w#2 w zp ZP_WORD:2 4.0
|
||||
(word~) print_word::w#21 w zp ZP_WORD:2 4.0
|
||||
(word) print_word::w#5 w zp ZP_WORD:2 4.0
|
||||
(word) print_word::w#6 w zp ZP_WORD:2 4.0
|
||||
(word) print_word::w#7 w zp ZP_WORD:2 4.0
|
||||
(word) print_word::w#8 w zp ZP_WORD:2 4.0
|
||||
(word) print_word::w#9 w zp ZP_WORD:2 4.0
|
||||
|
||||
reg byte x [ mul16s_compare::i#9 mul16s_compare::i#1 ]
|
||||
zp ZP_WORD:2 [ mul16s_compare::a#2 mul16s_compare::a#5 mul16s_compare::a#1 muls16s::a#0 mul16s::a#0 mul16s_error::a#0 print_sword::w#7 print_sword::w#6 print_sword::w#4 print_sword::w#5 print_sword::w#1 print_sword::w#2 print_sword::w#3 print_sword::w#0 print_word::w#10 print_word::w#8 print_word::w#9 print_word::w#5 print_word::w#6 print_word::w#7 print_word::w#17 print_word::w#18 print_word::w#1 print_word::w#2 print_word::w#21 mulf_tables_cmp::asm_sqr#2 mulf_tables_cmp::asm_sqr#1 mul16u_error::a#0 mul16u_compare::a#2 mul16u_compare::a#5 mul16u_compare::a#1 muls16u::a#0 mul8s_error::ms#0 mul8s_compare::ms#0 muls8s::return#2 muls8s::m#5 muls8s::return#0 muls8s::m#3 muls8s::m#1 muls8s::m#2 mul8u_error::ms#0 mul8u_compare::ms#0 muls8u::return#2 muls8u::return#0 muls8u::m#3 muls8u::m#1 mulf_init::sqr1_lo#2 mulf_init::sqr1_lo#1 mulf_init::sqr2_lo#2 mulf_init::sqr2_lo#1 print_cls::sc#2 print_cls::sc#1 ]
|
||||
zp ZP_WORD:4 [ mul16s_compare::b#2 mul16s_compare::b#5 mul16s_compare::b#1 muls16s::b#0 mul16s::b#0 mul16s_error::b#0 muls16u::i#2 muls16u::i#1 mul8s::m#4 mul8s::m#5 mul8s::m#1 mul8s::m#0 mul8s::m#2 mul8s::return#2 mul8s_compare::mn#0 mul8s_error::mn#0 mul8u::return#2 mul8u::res#2 mul8u::res#6 mul8u::res#1 mul8u::return#3 mul8u_compare::mn#0 mul8u_error::mn#0 mulf_tables_cmp::kc_sqr#2 mulf_tables_cmp::kc_sqr#1 mulf_init::sqr1_hi#2 mulf_init::sqr1_hi#1 mulf_init::sqr2_hi#2 mulf_init::sqr2_hi#1 ]
|
||||
reg byte y [ mul16s_compare::j#2 mul16s_compare::j#1 ]
|
||||
reg byte a [ mul16s_compare::ok#2 ]
|
||||
zp ZP_WORD:6 [ line_cursor#35 line_cursor#69 line_cursor#1 line_cursor#12 mulf_init::sqr#3 mulf_init::sqr#4 mulf_init::sqr#1 mulf_init::sqr#2 ]
|
||||
zp ZP_WORD:8 [ print_str::str#26 print_str::str#28 print_str::str#0 mul16u::a#3 mul16u::a#6 mul16u::a#8 mul16u::a#2 mul16u::a#0 muls16s::i#2 muls16s::i#1 muls16s::j#2 muls16s::j#1 mul8u::mb#2 mul8u::mb#0 mul8u::mb#1 mul16s::$6 mul16s::$16 mul16s::$12 mul16s::$17 ]
|
||||
zp ZP_DWORD:10 [ print_sdword::dw#4 print_sdword::dw#3 print_sdword::dw#1 print_sdword::dw#2 print_sdword::dw#0 print_dword::dw#3 print_dword::dw#1 print_dword::dw#2 print_dword::dw#0 mul16s_error::ms#0 mul16s_compare::ms#0 muls16s::return#2 muls16s::m#5 muls16s::return#0 muls16s::m#3 muls16s::m#1 muls16s::m#2 mul16u_error::ms#0 mul16u_compare::ms#0 muls16u::return#2 muls16u::return#0 muls16u::m#3 muls16u::m#1 ]
|
||||
reg byte x [ print_byte::b#5 print_byte::b#3 print_byte::b#4 print_byte::b#9 print_byte::b#1 print_byte::b#2 ]
|
||||
reg byte a [ print_char::ch#5 print_char::ch#3 print_char::ch#4 ]
|
||||
zp ZP_WORD:14 [ char_cursor#124 char_cursor#212 char_cursor#208 char_cursor#209 char_cursor#210 char_cursor#230 char_cursor#292 char_cursor#293 char_cursor#203 char_cursor#102 char_cursor#125 char_cursor#297 char_cursor#298 char_cursor#302 char_cursor#303 char_cursor#138 char_cursor#1 char_cursor#204 char_cursor#206 char_cursor#346 ]
|
||||
zp ZP_DWORD:16 [ mul16s::m#4 mul16s::m#5 mul16s::m#1 mul16s::m#0 mul16s::m#2 mul16u::return#2 mul16u::res#2 mul16u::res#6 mul16u::res#1 mul16s::return#0 mul16s::return#2 mul16s_compare::mn#0 mul16s_error::mn#0 mul16u::return#3 mul16u_compare::mn#0 mul16u_error::mn#0 ]
|
||||
zp ZP_WORD:20 [ mul16u::b#2 mul16u::b#3 mul16u::b#1 mul16u_compare::b#2 mul16u_compare::b#5 mul16u_compare::b#1 muls16u::b#0 mul16u_error::b#0 mulf8s::m#4 mulf8s::m#5 mulf8s::m#1 mulf8s::m#0 mulf8s::m#2 mulf8s::return#2 mul8s_compare::mf#0 mul8s_error::mf#0 mulf8u::return#2 mulf8u::return#0 mulf8u::return#3 mul8u_compare::mf#0 mul8u_error::mf#0 ]
|
||||
zp ZP_DWORD:22 [ mul16u::mb#2 mul16u::mb#0 mul16u::mb#1 ]
|
||||
reg byte x [ mul16u_compare::i#9 mul16u_compare::i#1 ]
|
||||
reg byte y [ mul16u_compare::j#2 mul16u_compare::j#1 ]
|
||||
reg byte a [ mul16u_compare::ok#2 ]
|
||||
zp ZP_BYTE:26 [ mul8s_compare::a#7 mul8s_compare::a#1 muls8s::a#0 mul8s::a#0 mul8u_compare::a#7 mul8u_compare::a#1 muls8u::a#0 mulf_init::x_2#3 mulf_init::x_2#2 mulf_init::x_2#1 mulf_init::dir#2 mulf_init::dir#3 ]
|
||||
zp ZP_BYTE:27 [ mul8s_compare::b#10 mul8s_compare::b#1 mulf8s::b#0 mul8s_error::b#0 mul8u_compare::b#10 mul8u_compare::b#1 mul8u_error::b#0 ]
|
||||
reg byte x [ mul8s_compare::ok#3 mul8s_compare::ok#4 ]
|
||||
reg byte x [ print_sbyte::b#4 print_sbyte::b#3 print_sbyte::b#1 print_sbyte::b#2 print_sbyte::b#0 ]
|
||||
reg byte a [ mul8u::b#2 mul8u::b#3 mul8u::b#1 ]
|
||||
reg byte x [ mul8u::a#3 mul8u::a#6 mul8u::a#8 mul8u::a#2 mul8u::a#0 ]
|
||||
reg byte a [ mulf8u::a#2 mulf8u::a#1 mulf8u::a#4 ]
|
||||
reg byte x [ mulf8u::b#2 mulf8u::b#1 mulf8u::b#4 ]
|
||||
reg byte y [ muls8s::i#2 muls8s::i#1 ]
|
||||
reg byte y [ muls8s::j#2 muls8s::j#1 ]
|
||||
reg byte x [ mul8u_compare::ok#3 mul8u_compare::ok#4 ]
|
||||
reg byte y [ muls8u::i#2 muls8u::i#1 ]
|
||||
reg byte x [ mulf_init::c#2 mulf_init::c#1 ]
|
||||
reg byte x [ mulf_init::x_255#2 mulf_init::x_255#1 ]
|
||||
reg byte a [ print_byte::$0 ]
|
||||
reg byte a [ print_byte::$2 ]
|
||||
reg byte a [ mul16u::$1 ]
|
||||
reg byte x [ muls8s::b#0 ]
|
||||
reg byte y [ mulf8s::a#0 ]
|
||||
reg byte y [ mul8s::b#0 ]
|
||||
reg byte x [ mul8s_error::a#0 ]
|
||||
reg byte a [ mul8s::$6 ]
|
||||
reg byte a [ mul8s::$16 ]
|
||||
reg byte a [ mul8s::$12 ]
|
||||
reg byte a [ mul8s::$17 ]
|
||||
reg byte a [ mul8u::$1 ]
|
||||
reg byte a [ mulf8s::$6 ]
|
||||
reg byte a [ mulf8s::$16 ]
|
||||
reg byte a [ mulf8s::$12 ]
|
||||
reg byte a [ mulf8s::$17 ]
|
||||
reg byte x [ muls8u::b#0 ]
|
||||
reg byte x [ mul8u_error::a#0 ]
|
||||
reg byte a [ mulf_init::$2 ]
|
||||
reg byte a [ mulf_init::$5 ]
|
||||
reg byte a [ mulf_init::$6 ]
|
Loading…
x
Reference in New Issue
Block a user