mirror of
https://gitlab.com/camelot/kickc.git
synced 2025-01-01 13:30:50 +00:00
Added a test for a pseudo random number generator and struct-of-arrays vs array of strucs.
This commit is contained in:
parent
b2052e0ab4
commit
60e6d3a645
@ -0,0 +1,6 @@
|
||||
lda {m1}
|
||||
eor {m2}
|
||||
sta {m1}
|
||||
lda {m1}+1
|
||||
eor {m2}+1
|
||||
sta {m1}+1
|
@ -0,0 +1,6 @@
|
||||
lda {m2}
|
||||
eor {m3}
|
||||
sta {m1}
|
||||
lda {m2}+1
|
||||
eor {m3}+1
|
||||
sta {m1}+1
|
18
src/main/fragment/mos6502-common/vwum1=vwum2_rol_7.asm
Normal file
18
src/main/fragment/mos6502-common/vwum1=vwum2_rol_7.asm
Normal file
@ -0,0 +1,18 @@
|
||||
lda {m2}
|
||||
asl
|
||||
sta {m1}
|
||||
lda {m2}+1
|
||||
rol
|
||||
sta {m1}+1
|
||||
asl {m1}
|
||||
rol {m1}+1
|
||||
asl {m1}
|
||||
rol {m1}+1
|
||||
asl {m1}
|
||||
rol {m1}+1
|
||||
asl {m1}
|
||||
rol {m1}+1
|
||||
asl {m1}
|
||||
rol {m1}+1
|
||||
asl {m1}
|
||||
rol {m1}+1
|
@ -40,6 +40,28 @@ public class TestPrograms {
|
||||
public TestPrograms() {
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testPolygon() throws IOException, URISyntaxException {
|
||||
compileAndCompare("complex/polygon/polygon.c");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testPrngXorshift() throws IOException, URISyntaxException {
|
||||
compileAndCompare("prng-xorshift.c");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testStars2() throws IOException, URISyntaxException {
|
||||
compileAndCompare("stars-2.c");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testStars1() throws IOException, URISyntaxException {
|
||||
compileAndCompare("stars-1.c");
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* TODO: Add support for var*var
|
||||
@Test
|
||||
public void testMultiply3() throws IOException, URISyntaxException {
|
||||
|
281
src/test/kc/complex/polygon/polygon.c
Normal file
281
src/test/kc/complex/polygon/polygon.c
Normal file
@ -0,0 +1,281 @@
|
||||
// Filling a simple 16x16 2D polygon using EOR-filling
|
||||
// - Clearing canvas
|
||||
// - Trivial 2D rotation using sine tables
|
||||
// - Line-drawing polygon edges (fill-ready lines)
|
||||
// - Up-to-down EOR filling
|
||||
// - Double buffering
|
||||
|
||||
#include <string.h>
|
||||
#include <c64.h>
|
||||
#include <time.h>
|
||||
#include <stdio.h>
|
||||
#include <conio.h>
|
||||
|
||||
#define DEBUG
|
||||
|
||||
// The screen matrix
|
||||
char* const SCREEN = 0x2c00;
|
||||
// The two charsets used for double buffering
|
||||
char* const CANVAS1 = 0x3000;
|
||||
char* const CANVAS2 = 0x3800;
|
||||
|
||||
// The screen console
|
||||
char* const CONSOLE = 0x0400;
|
||||
// The default charset address
|
||||
char* const PETSCII = 0x1000;
|
||||
|
||||
// The current canvas being rendered to the screen - in D018 format.
|
||||
char volatile canvas_show_memory = toD018(SCREEN, CANVAS2);
|
||||
// Flag signalling that the canvas on screen needs to be updated.
|
||||
// Set to 1 by the renderer when a new canvas is ready for showing, and to 0 by the raster when the canvas is shown on screen.
|
||||
char volatile canvas_show_flag = 0;
|
||||
|
||||
// SIN/COS tables
|
||||
char align(0x100) SINTAB[0x140] = kickasm {{
|
||||
.fill $200, 63 + 63*sin(i*2*PI/$100)
|
||||
}};
|
||||
char* COSTAB = SINTAB+0x40;
|
||||
|
||||
void main() {
|
||||
// Clear the screen & canvasses
|
||||
memset(SCREEN, 0, 40*25);
|
||||
memset(COLS, BLACK, 40*25);
|
||||
// Setup 16x16 canvas for rendering
|
||||
char *screen= SCREEN+12, *cols=COLS+12;
|
||||
for(char y=0;y<16;y++) {
|
||||
char c=y;
|
||||
for(char x=0;x<16;x++) {
|
||||
cols[x] = WHITE;
|
||||
screen[x] = c;
|
||||
c+=0x10;
|
||||
}
|
||||
cols += 40;
|
||||
screen += 40;
|
||||
}
|
||||
VICII->BORDER_COLOR = BLACK;
|
||||
VICII->BG_COLOR = BLACK;
|
||||
|
||||
// Set-up the raster IRQ
|
||||
setup_irq();
|
||||
// Set text color
|
||||
textcolor(WHITE);
|
||||
|
||||
char p0_idx = 0x88;
|
||||
char p1_idx = p0_idx+15;
|
||||
char p2_idx = p0_idx+170;
|
||||
|
||||
// The current canvas being rendered to
|
||||
char* canvas = CANVAS1;
|
||||
|
||||
while(1) {
|
||||
clock_start();
|
||||
// Clear canvas
|
||||
memset(canvas, 0, 0x0800);
|
||||
// Plot on canvas
|
||||
char x0 = COSTAB[p0_idx];
|
||||
char y0 = SINTAB[p0_idx];
|
||||
char x1 = COSTAB[p1_idx];
|
||||
char y1 = SINTAB[p1_idx];
|
||||
line(canvas, x0, y0, x1, y1);
|
||||
char x2 = COSTAB[p2_idx];
|
||||
char y2 = SINTAB[p2_idx];
|
||||
//line(canvas, x1, y1, x2, y2);
|
||||
//line(canvas, x2, y2, x0, y0);
|
||||
// Move idx
|
||||
//p0_idx++;
|
||||
//p1_idx++;
|
||||
//p2_idx++;
|
||||
// Fill canvas
|
||||
//eorfill(canvas);
|
||||
// Swap canvas to show on screen (using XOR)
|
||||
canvas_show_memory ^= toD018(SCREEN,CANVAS1)^toD018(SCREEN,CANVAS2);
|
||||
// swap canvas being rendered to (using XOR)
|
||||
canvas ^= (CANVAS1^CANVAS2);
|
||||
// Read and display cycles
|
||||
clock_t cyclecount = clock()-CLOCKS_PER_INIT;
|
||||
gotoxy(0,24);
|
||||
//printf("frame: %02x cycles: %6lu", p0_idx, cyclecount);
|
||||
printf("(%02x,%02x)-(%02x,%02x)", x0, y0, x1, y1);
|
||||
// Wait until the canvas on screen has been switched before starting work on the next frame
|
||||
canvas_show_flag = 1;
|
||||
while(canvas_show_flag) {}
|
||||
}
|
||||
}
|
||||
|
||||
// Setup raster IRQ to change charset at different lines
|
||||
void setup_irq() {
|
||||
asm { sei }
|
||||
// Disable CIA 1 Timer IRQ
|
||||
CIA1->INTERRUPT = CIA_INTERRUPT_CLEAR;
|
||||
// Set raster line to 8 pixels before the border
|
||||
VICII->CONTROL1 &= 0x7f;
|
||||
VICII->RASTER = BORDER_YPOS_BOTTOM-8;
|
||||
// Enable Raster Interrupt
|
||||
VICII->IRQ_ENABLE = IRQ_RASTER;
|
||||
// Set the IRQ routine
|
||||
*KERNEL_IRQ = &irq_bottom_1;
|
||||
asm { cli }
|
||||
}
|
||||
|
||||
// Interrupt Routine 1: Just above last text line.
|
||||
interrupt(kernel_min) void irq_bottom_1() {
|
||||
// Change border color
|
||||
VICII->BORDER_COLOR = WHITE;
|
||||
// Show the cycle counter
|
||||
VICII->MEMORY = toD018(CONSOLE, PETSCII);
|
||||
// Acknowledge the IRQ
|
||||
VICII->IRQ_STATUS = IRQ_RASTER;
|
||||
// Trigger IRQ 2 at bottom of text-line
|
||||
VICII->RASTER = BORDER_YPOS_BOTTOM;
|
||||
*KERNEL_IRQ = &irq_bottom_2;
|
||||
}
|
||||
|
||||
// Interrupt Routine 2
|
||||
interrupt(kernel_keyboard) void irq_bottom_2() {
|
||||
// Change border color
|
||||
VICII->BORDER_COLOR = BLACK;
|
||||
// Show the current canvas (unless a key is being pressed)
|
||||
if(!kbhit()) {
|
||||
VICII->MEMORY = canvas_show_memory;
|
||||
}
|
||||
canvas_show_flag = 0;
|
||||
// Acknowledge the IRQ
|
||||
VICII->IRQ_STATUS = IRQ_RASTER;
|
||||
// Trigger IRQ 1 at 8 pixels before the border
|
||||
VICII->RASTER = BORDER_YPOS_BOTTOM-8;
|
||||
*KERNEL_IRQ = &irq_bottom_1;
|
||||
}
|
||||
|
||||
// Draw a EOR friendly line between two points
|
||||
// Uses bresenham line drawing routine
|
||||
void line(char* canvas, char x1, char y1, char x2, char y2) {
|
||||
char x = x1;
|
||||
char y = y1;
|
||||
char dx = abs_u8(x2-x1);
|
||||
char dy = abs_u8(y2-y1);
|
||||
char sx = sgn_u8(x2-x1);
|
||||
char sy = sgn_u8(y2-y1);
|
||||
if(sx==0xff) {
|
||||
// The sign of the x-difference determines if this is a line at the top of the face
|
||||
// being filled or a line at the bottom of the face. Because the points are organized in a clockwise
|
||||
// fashion any line pointing right is filled below the line and any line pointing left is filled above
|
||||
// If this line is pointing left then move it down one pixel to ensure the fill is stopped correctly
|
||||
y++; y2++;
|
||||
}
|
||||
#ifdef DEBUG
|
||||
gotoxy(0,0);
|
||||
printf("dx:%02x dy:%02x sx:%02x sy:%02x",dx,dy,sx,sy);
|
||||
char print_col = 0;
|
||||
char print_row = 1;
|
||||
#endif
|
||||
|
||||
if(dx > dy) {
|
||||
// X is the driver - plot every X using bresenham
|
||||
char e = dx/2;
|
||||
do {
|
||||
#ifdef DEBUG
|
||||
if(print_col<40-8) {
|
||||
gotoxy(print_col, print_row);
|
||||
printf("%02x %02x %02x",x,y,e);
|
||||
if(++print_row==24) {
|
||||
print_row = 1;
|
||||
print_col +=9;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
plot(canvas, x, y);
|
||||
x += sx;
|
||||
e += dy;
|
||||
if(dx < e) {
|
||||
y += sy;
|
||||
e -= dx;
|
||||
}
|
||||
} while (x != x2);
|
||||
plot(canvas, x, y);
|
||||
} else {
|
||||
// Y is the driver - only plot one plot per X
|
||||
char e = dy/2;
|
||||
#ifdef DEBUG
|
||||
if(print_col<40-8) {
|
||||
gotoxy(print_col, print_row);
|
||||
printf("%02x %02x %02x",x,y,e);
|
||||
if(++print_row==24) {
|
||||
print_row = 1;
|
||||
print_col +=9;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
plot(canvas, x, y);
|
||||
do {
|
||||
y += sy;
|
||||
e += dx;
|
||||
if(dy<e) {
|
||||
x += sx;
|
||||
e -= dy;
|
||||
#ifdef DEBUG
|
||||
if(print_col<40-8) {
|
||||
gotoxy(print_col, print_row);
|
||||
printf("%02x %02x %02x",x,y,e);
|
||||
if(++print_row==24) {
|
||||
print_row = 1;
|
||||
print_col +=9;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
plot(canvas, x, y);
|
||||
} else {
|
||||
printf("*");
|
||||
}
|
||||
} while (y != y2);
|
||||
#ifdef DEBUG
|
||||
gotoxy(20,24);
|
||||
printf("(%02x,%02x)", x, y);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
// Column offsets
|
||||
unsigned int plot_column[] = { 0, 1*128, 2*128, 3*128, 4*128, 5*128, 6*128, 7*128, 8*128, 9*128, 10*128, 11*128, 12*128, 13*128, 14*128, 15*128 };
|
||||
// The bits used for plotting a pixel
|
||||
char plot_bit[] = { 0x80, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x01};
|
||||
|
||||
// Plot a single point on the canvas
|
||||
inline void plot(char* canvas, char x, char y) {
|
||||
// Find the canvas column
|
||||
char* column = canvas + plot_column[x/8];
|
||||
// Plot the bit
|
||||
column[y] |= plot_bit[x&7];
|
||||
}
|
||||
|
||||
// EOR fill
|
||||
void eorfill(char* canvas) {
|
||||
char* column = canvas;
|
||||
for(char x=0;x<16;x++) {
|
||||
char eor = column[0];
|
||||
for(char y=1;y<16*8;y++) {
|
||||
eor ^= column[y];
|
||||
column[y] = eor;
|
||||
}
|
||||
column += 16*8;
|
||||
}
|
||||
}
|
||||
|
||||
// Get the absolute value of a u-bit unsigned number treated as a signed number.
|
||||
unsigned char abs_u8(unsigned char u) {
|
||||
if(u & 0x80) {
|
||||
return -u;
|
||||
} else {
|
||||
return u;
|
||||
}
|
||||
}
|
||||
|
||||
// Get the sign of a 8-bit unsigned number treated as a signed number.
|
||||
// Returns unsigned -1 if the number is negative
|
||||
unsigned char sgn_u8(unsigned char u) {
|
||||
if(u & 0x80) {
|
||||
return -1;
|
||||
} else {
|
||||
return 1;
|
||||
}
|
||||
}
|
53
src/test/kc/prng-xorshift.c
Normal file
53
src/test/kc/prng-xorshift.c
Normal file
@ -0,0 +1,53 @@
|
||||
// Test the xorshift pseudorandom number generator
|
||||
// Source http://www.retroprogramming.com/2017/07/xorshift-pseudorandom-numbers-in-z80.html
|
||||
// Information https://en.wikipedia.org/wiki/Xorshift
|
||||
|
||||
#include <stdio.h>
|
||||
#include <c64.h>
|
||||
|
||||
void main() {
|
||||
clrscr();
|
||||
textcolor(WHITE);
|
||||
printf("generating unique randoms...");
|
||||
unsigned int first = rand();
|
||||
unsigned long cnt = 0;
|
||||
textcolor(LIGHT_BLUE);
|
||||
char col = 3, row = 1;
|
||||
unsigned int rnd = first;
|
||||
do {
|
||||
cnt++;
|
||||
if((char)cnt==0) {
|
||||
gotoxy(col,row);
|
||||
printf("%5u",rnd);
|
||||
if(++row==25) {
|
||||
row = 1;
|
||||
col+=6;
|
||||
if(col>40-5)
|
||||
col = 3;
|
||||
}
|
||||
}
|
||||
rnd = rand();
|
||||
} while(rnd!=first);
|
||||
gotoxy(28,0);
|
||||
printf("found %lu",cnt);
|
||||
}
|
||||
|
||||
|
||||
// The maximal random value
|
||||
#define RAND_MAX 65335
|
||||
|
||||
// The random state variable
|
||||
unsigned int rand_state = 1;
|
||||
|
||||
// Returns a pseudo-random number in the range of 0 to RAND_MAX (65535)
|
||||
unsigned int rand() {
|
||||
rand_state ^= rand_state << 7;
|
||||
rand_state ^= rand_state >> 9;
|
||||
rand_state ^= rand_state << 8;
|
||||
return rand_state;
|
||||
}
|
||||
|
||||
// Seeds the random number generator used by the function rand.
|
||||
void srand(unsigned int seed) {
|
||||
rand_state = seed;
|
||||
}
|
28
src/test/kc/stars-1.c
Normal file
28
src/test/kc/stars-1.c
Normal file
@ -0,0 +1,28 @@
|
||||
// Stars array of struct
|
||||
#include <stdio.h>
|
||||
#include <conio.h>
|
||||
|
||||
typedef struct {
|
||||
char star_x;
|
||||
char star_y;
|
||||
char speed_x;
|
||||
char speed_y;
|
||||
} star_t;
|
||||
|
||||
star_t stars[5] = {
|
||||
{50, 50, 2, 7},
|
||||
{40, 70, 2, 7},
|
||||
{30, 20, 2, 7},
|
||||
{70, 10, 2, 7},
|
||||
{40, 80, 2, 7}
|
||||
};
|
||||
|
||||
void main()
|
||||
{
|
||||
clrscr();
|
||||
star_t *pStar = stars;
|
||||
for( char i=0;i<5;i++) {
|
||||
printf("%p %u %u\n", pStar, pStar->star_x, pStar->star_y);
|
||||
pStar++;
|
||||
}
|
||||
}
|
25
src/test/kc/stars-2.c
Normal file
25
src/test/kc/stars-2.c
Normal file
@ -0,0 +1,25 @@
|
||||
// Stars struct of array
|
||||
#include <stdio.h>
|
||||
#include <conio.h>
|
||||
|
||||
typedef struct {
|
||||
char star_x[5];
|
||||
char star_y[5];
|
||||
char speed_x[5];
|
||||
char speed_y[5];
|
||||
} star_t;
|
||||
|
||||
star_t stars = {
|
||||
{50, 40, 30, 70, 40},
|
||||
{50, 70, 20, 10, 80},
|
||||
{ 2, 2, 2, 2, 2},
|
||||
{ 7, 7, 7, 7, 7}
|
||||
};
|
||||
|
||||
void main()
|
||||
{
|
||||
clrscr();
|
||||
for(char i=0;i<5;i++) {
|
||||
printf("%u %u\n", stars.star_x[i], stars.star_y[i]);
|
||||
}
|
||||
}
|
1572
src/test/ref/complex/polygon/polygon.asm
Normal file
1572
src/test/ref/complex/polygon/polygon.asm
Normal file
File diff suppressed because it is too large
Load Diff
885
src/test/ref/complex/polygon/polygon.cfg
Normal file
885
src/test/ref/complex/polygon/polygon.cfg
Normal file
@ -0,0 +1,885 @@
|
||||
@begin: scope:[] from
|
||||
[0] phi()
|
||||
to:@1
|
||||
@1: scope:[] from @begin
|
||||
[1] (byte) conio_cursor_x ← (byte) 0
|
||||
[2] (byte) conio_cursor_y ← (byte) 0
|
||||
[3] (byte*) conio_cursor_text ← (const nomodify byte*) CONIO_SCREEN_TEXT
|
||||
[4] (byte*) conio_cursor_color ← (const nomodify byte*) CONIO_SCREEN_COLORS
|
||||
[5] (byte) conio_textcolor ← (const nomodify byte) CONIO_TEXTCOLOR_DEFAULT
|
||||
to:toD0181
|
||||
toD0181: scope:[] from @1
|
||||
[6] phi()
|
||||
to:@3
|
||||
@3: scope:[] from toD0181
|
||||
[7] (volatile byte) canvas_show_memory ← (const byte) toD0181_return#0
|
||||
[8] (volatile byte) canvas_show_flag ← (byte) 0
|
||||
to:@2
|
||||
@2: scope:[] from @3
|
||||
[9] phi()
|
||||
[10] call main
|
||||
to:@end
|
||||
@end: scope:[] from @2
|
||||
[11] phi()
|
||||
|
||||
(void()) main()
|
||||
main: scope:[main] from @2
|
||||
[12] phi()
|
||||
[13] call memset
|
||||
to:main::@11
|
||||
main::@11: scope:[main] from main
|
||||
[14] phi()
|
||||
[15] call memset
|
||||
to:main::@1
|
||||
main::@1: scope:[main] from main::@11 main::@6
|
||||
[16] (byte*) main::screen#5 ← phi( main::@11/(const nomodify byte*) SCREEN+(byte) $c main::@6/(byte*) main::screen#1 )
|
||||
[16] (byte*) main::cols#5 ← phi( main::@11/(const nomodify byte*) COLS+(byte) $c main::@6/(byte*) main::cols#1 )
|
||||
[16] (byte) main::y#2 ← phi( main::@11/(byte) 0 main::@6/(byte) main::y#1 )
|
||||
[17] if((byte) main::y#2<(byte) $10) goto main::@2
|
||||
to:main::@3
|
||||
main::@3: scope:[main] from main::@1
|
||||
[18] *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR) ← (const nomodify byte) BLACK
|
||||
[19] *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_BG_COLOR) ← (const nomodify byte) BLACK
|
||||
[20] call setup_irq
|
||||
to:main::@12
|
||||
main::@12: scope:[main] from main::@3
|
||||
[21] phi()
|
||||
[22] call textcolor
|
||||
to:main::@7
|
||||
main::@7: scope:[main] from main::@12 main::@26
|
||||
[23] (byte*) main::canvas#10 ← phi( main::@12/(const nomodify byte*) CANVAS1 main::@26/(byte*) main::canvas#25 )
|
||||
to:main::@8
|
||||
main::@8: scope:[main] from main::@7
|
||||
[24] phi()
|
||||
[25] call clock_start
|
||||
to:main::@13
|
||||
main::@13: scope:[main] from main::@8
|
||||
[26] (void*) memset::str#4 ← (void*)(byte*) main::canvas#10
|
||||
[27] call memset
|
||||
to:main::@14
|
||||
main::@14: scope:[main] from main::@13
|
||||
[28] (byte) main::x0#0 ← *((const byte*) COSTAB+(const byte) main::p0_idx)
|
||||
[29] (byte) main::y0#0 ← *((const byte*) SINTAB+(const byte) main::p0_idx)
|
||||
[30] (byte) main::x1#0 ← *((const byte*) COSTAB+(const byte) main::p1_idx#0)
|
||||
[31] (byte) main::y1#0 ← *((const byte*) SINTAB+(const byte) main::p1_idx#0)
|
||||
[32] (byte*) line::canvas#0 ← (byte*) main::canvas#10
|
||||
[33] (byte) line::x1#0 ← (byte) main::x0#0
|
||||
[34] (byte) line::y1#0 ← (byte) main::y0#0
|
||||
[35] (byte) line::x2#0 ← (byte) main::x1#0
|
||||
[36] (byte) line::y2#0 ← (byte) main::y1#0
|
||||
[37] call line
|
||||
to:main::toD0181
|
||||
main::toD0181: scope:[main] from main::@14
|
||||
[38] phi()
|
||||
to:main::toD0182
|
||||
main::toD0182: scope:[main] from main::toD0181
|
||||
[39] phi()
|
||||
to:main::@10
|
||||
main::@10: scope:[main] from main::toD0182
|
||||
[40] (volatile byte) canvas_show_memory ← (volatile byte) canvas_show_memory ^ (const byte) main::toD0181_return#0^(const byte) main::toD0182_return#0
|
||||
[41] (word) main::canvas#1 ← (byte*) main::canvas#10 ^ (const nomodify byte*) CANVAS1^(const nomodify byte*) CANVAS2
|
||||
[42] call clock
|
||||
to:main::@15
|
||||
main::@15: scope:[main] from main::@10
|
||||
[43] phi()
|
||||
[44] call gotoxy
|
||||
to:main::@16
|
||||
main::@16: scope:[main] from main::@15
|
||||
[45] phi()
|
||||
[46] call cputs
|
||||
to:main::@17
|
||||
main::@17: scope:[main] from main::@16
|
||||
[47] (byte) printf_uchar::uvalue#0 ← (byte) main::x0#0
|
||||
[48] call printf_uchar
|
||||
to:main::@18
|
||||
main::@18: scope:[main] from main::@17
|
||||
[49] phi()
|
||||
[50] call cputs
|
||||
to:main::@19
|
||||
main::@19: scope:[main] from main::@18
|
||||
[51] (byte) printf_uchar::uvalue#1 ← (byte) main::y0#0
|
||||
[52] call printf_uchar
|
||||
to:main::@20
|
||||
main::@20: scope:[main] from main::@19
|
||||
[53] phi()
|
||||
[54] call cputs
|
||||
to:main::@21
|
||||
main::@21: scope:[main] from main::@20
|
||||
[55] (byte) printf_uchar::uvalue#2 ← (byte) main::x1#0
|
||||
[56] call printf_uchar
|
||||
to:main::@22
|
||||
main::@22: scope:[main] from main::@21
|
||||
[57] phi()
|
||||
[58] call cputs
|
||||
to:main::@23
|
||||
main::@23: scope:[main] from main::@22
|
||||
[59] (byte) printf_uchar::uvalue#3 ← (byte) main::y1#0
|
||||
[60] call printf_uchar
|
||||
to:main::@24
|
||||
main::@24: scope:[main] from main::@23
|
||||
[61] phi()
|
||||
[62] call cputs
|
||||
to:main::@25
|
||||
main::@25: scope:[main] from main::@24
|
||||
[63] (volatile byte) canvas_show_flag ← (byte) 1
|
||||
to:main::@9
|
||||
main::@9: scope:[main] from main::@25 main::@9
|
||||
[64] if((byte) 0!=(volatile byte) canvas_show_flag) goto main::@9
|
||||
to:main::@26
|
||||
main::@26: scope:[main] from main::@9
|
||||
[65] (byte*) main::canvas#25 ← (byte*)(word) main::canvas#1
|
||||
to:main::@7
|
||||
main::@2: scope:[main] from main::@1
|
||||
[66] (byte) main::c#4 ← (byte) main::y#2
|
||||
to:main::@4
|
||||
main::@4: scope:[main] from main::@2 main::@5
|
||||
[67] (byte) main::c#2 ← phi( main::@2/(byte) main::c#4 main::@5/(byte) main::c#1 )
|
||||
[67] (byte) main::x#2 ← phi( main::@2/(byte) 0 main::@5/(byte) main::x#1 )
|
||||
[68] if((byte) main::x#2<(byte) $10) goto main::@5
|
||||
to:main::@6
|
||||
main::@6: scope:[main] from main::@4
|
||||
[69] (byte*) main::cols#1 ← (byte*) main::cols#5 + (byte) $28
|
||||
[70] (byte*) main::screen#1 ← (byte*) main::screen#5 + (byte) $28
|
||||
[71] (byte) main::y#1 ← ++ (byte) main::y#2
|
||||
to:main::@1
|
||||
main::@5: scope:[main] from main::@4
|
||||
[72] *((byte*) main::cols#5 + (byte) main::x#2) ← (const nomodify byte) WHITE
|
||||
[73] *((byte*) main::screen#5 + (byte) main::x#2) ← (byte) main::c#2
|
||||
[74] (byte) main::c#1 ← (byte) main::c#2 + (byte) $10
|
||||
[75] (byte) main::x#1 ← ++ (byte) main::x#2
|
||||
to:main::@4
|
||||
|
||||
(void()) cputs((to_nomodify byte*) cputs::s)
|
||||
cputs: scope:[cputs] from line::@10 line::@25 line::@27 line::@29 line::@31 line::@35 line::@37 line::@40 line::@42 line::@45 line::@47 line::@49 line::@51 line::@53 main::@16 main::@18 main::@20 main::@22 main::@24 printf_number_buffer::@3
|
||||
[76] (to_nomodify byte*) cputs::s#22 ← phi( line::@10/(const byte*) line::s6 line::@25/(const byte*) line::s line::@27/(const byte*) line::s1 line::@29/(const byte*) line::s2 line::@31/(const byte*) line::s3 line::@35/(const byte*) line::s4 line::@37/(const byte*) line::s4 line::@40/(const byte*) line::s4 line::@42/(const byte*) line::s4 line::@45/(const byte*) s line::@47/(const byte*) s1 line::@49/(const byte*) s4 line::@51/(const byte*) line::s4 line::@53/(const byte*) line::s4 main::@16/(const byte*) s main::@18/(const byte*) s1 main::@20/(const byte*) main::s2 main::@22/(const byte*) s1 main::@24/(const byte*) s4 printf_number_buffer::@3/(const byte*) printf_number_buffer::buffer_digits#0 )
|
||||
to:cputs::@1
|
||||
cputs::@1: scope:[cputs] from cputs cputs::@2
|
||||
[77] (to_nomodify byte*) cputs::s#21 ← phi( cputs/(to_nomodify byte*) cputs::s#22 cputs::@2/(to_nomodify byte*) cputs::s#0 )
|
||||
[78] (byte) cputs::c#1 ← *((to_nomodify byte*) cputs::s#21)
|
||||
[79] (to_nomodify byte*) cputs::s#0 ← ++ (to_nomodify byte*) cputs::s#21
|
||||
[80] if((byte) 0!=(byte) cputs::c#1) goto cputs::@2
|
||||
to:cputs::@return
|
||||
cputs::@return: scope:[cputs] from cputs::@1
|
||||
[81] return
|
||||
to:@return
|
||||
cputs::@2: scope:[cputs] from cputs::@1
|
||||
[82] (byte) cputc::c#0 ← (byte) cputs::c#1
|
||||
[83] call cputc
|
||||
to:cputs::@1
|
||||
|
||||
(void()) cputc((byte) cputc::c)
|
||||
cputc: scope:[cputc] from cputs::@2 printf_number_buffer::@6 printf_padding::@2
|
||||
[84] (byte) cputc::c#3 ← phi( cputs::@2/(byte) cputc::c#0 printf_number_buffer::@6/(byte) cputc::c#2 printf_padding::@2/(byte) '0' )
|
||||
[85] if((byte) cputc::c#3==(byte) '
|
||||
') goto cputc::@1
|
||||
to:cputc::@2
|
||||
cputc::@2: scope:[cputc] from cputc
|
||||
[86] *((byte*) conio_cursor_text) ← (byte) cputc::c#3
|
||||
[87] (byte*) conio_cursor_text ← ++ (byte*) conio_cursor_text
|
||||
[88] *((byte*) conio_cursor_color) ← (byte) conio_textcolor
|
||||
[89] (byte*) conio_cursor_color ← ++ (byte*) conio_cursor_color
|
||||
[90] (byte) conio_cursor_x ← ++ (byte) conio_cursor_x
|
||||
[91] if((byte) conio_cursor_x!=(byte) $28) goto cputc::@return
|
||||
to:cputc::@3
|
||||
cputc::@3: scope:[cputc] from cputc::@2
|
||||
[92] (byte) conio_cursor_x ← (byte) 0
|
||||
[93] (byte) conio_cursor_y ← ++ (byte) conio_cursor_y
|
||||
[94] call cscroll
|
||||
to:cputc::@return
|
||||
cputc::@return: scope:[cputc] from cputc::@1 cputc::@2 cputc::@3
|
||||
[95] return
|
||||
to:@return
|
||||
cputc::@1: scope:[cputc] from cputc
|
||||
[96] phi()
|
||||
[97] call cputln
|
||||
to:cputc::@return
|
||||
|
||||
(void()) cputln()
|
||||
cputln: scope:[cputln] from cputc::@1
|
||||
[98] (byte*~) cputln::$0 ← (byte*) conio_cursor_text - (byte) conio_cursor_x
|
||||
[99] (byte*~) cputln::$1 ← (byte*~) cputln::$0 + (byte) $28
|
||||
[100] (byte*) conio_cursor_text ← (byte*~) cputln::$1
|
||||
[101] (byte*~) cputln::$2 ← (byte*) conio_cursor_color - (byte) conio_cursor_x
|
||||
[102] (byte*~) cputln::$3 ← (byte*~) cputln::$2 + (byte) $28
|
||||
[103] (byte*) conio_cursor_color ← (byte*~) cputln::$3
|
||||
[104] (byte) conio_cursor_x ← (byte) 0
|
||||
[105] (byte) conio_cursor_y ← ++ (byte) conio_cursor_y
|
||||
[106] call cscroll
|
||||
to:cputln::@return
|
||||
cputln::@return: scope:[cputln] from cputln
|
||||
[107] return
|
||||
to:@return
|
||||
|
||||
(void()) cscroll()
|
||||
cscroll: scope:[cscroll] from cputc::@3 cputln
|
||||
[108] if((byte) conio_cursor_y!=(byte) $19) goto cscroll::@return
|
||||
to:cscroll::@1
|
||||
cscroll::@1: scope:[cscroll] from cscroll
|
||||
[109] phi()
|
||||
[110] call memcpy
|
||||
to:cscroll::@2
|
||||
cscroll::@2: scope:[cscroll] from cscroll::@1
|
||||
[111] phi()
|
||||
[112] call memcpy
|
||||
to:cscroll::@3
|
||||
cscroll::@3: scope:[cscroll] from cscroll::@2
|
||||
[113] phi()
|
||||
[114] call memset
|
||||
to:cscroll::@4
|
||||
cscroll::@4: scope:[cscroll] from cscroll::@3
|
||||
[115] (byte) memset::c#1 ← (byte) conio_textcolor
|
||||
[116] call memset
|
||||
to:cscroll::@5
|
||||
cscroll::@5: scope:[cscroll] from cscroll::@4
|
||||
[117] (byte*~) cscroll::$7 ← (byte*) conio_cursor_text - (byte) $28
|
||||
[118] (byte*) conio_cursor_text ← (byte*~) cscroll::$7
|
||||
[119] (byte*~) cscroll::$8 ← (byte*) conio_cursor_color - (byte) $28
|
||||
[120] (byte*) conio_cursor_color ← (byte*~) cscroll::$8
|
||||
[121] (byte) conio_cursor_y ← -- (byte) conio_cursor_y
|
||||
to:cscroll::@return
|
||||
cscroll::@return: scope:[cscroll] from cscroll cscroll::@5
|
||||
[122] return
|
||||
to:@return
|
||||
|
||||
(void*()) memset((void*) memset::str , (byte) memset::c , (word) memset::num)
|
||||
memset: scope:[memset] from cscroll::@3 cscroll::@4 main main::@11 main::@13
|
||||
[123] (byte) memset::c#7 ← phi( cscroll::@3/(byte) ' ' cscroll::@4/(byte) memset::c#1 main/(byte) 0 main::@11/(const nomodify byte) BLACK main::@13/(byte) 0 )
|
||||
[123] (void*) memset::str#6 ← phi( cscroll::@3/(void*)(const nomodify byte*) CONIO_SCREEN_TEXT+(word)(number) $19*(number) $28-(byte) $28 cscroll::@4/(void*)(const nomodify byte*) CONIO_SCREEN_COLORS+(word)(number) $19*(number) $28-(byte) $28 main/(void*)(const nomodify byte*) SCREEN main::@11/(void*)(const nomodify byte*) COLS main::@13/(void*) memset::str#4 )
|
||||
[123] (word) memset::num#5 ← phi( cscroll::@3/(byte) $28 cscroll::@4/(byte) $28 main/(word)(number) $28*(number) $19 main::@11/(word)(number) $28*(number) $19 main::@13/(word) $800 )
|
||||
[124] if((word) memset::num#5<=(byte) 0) goto memset::@return
|
||||
to:memset::@1
|
||||
memset::@1: scope:[memset] from memset
|
||||
[125] (byte*) memset::end#0 ← (byte*)(void*) memset::str#6 + (word) memset::num#5
|
||||
[126] (byte*) memset::dst#4 ← (byte*)(void*) memset::str#6
|
||||
to:memset::@2
|
||||
memset::@2: scope:[memset] from memset::@1 memset::@3
|
||||
[127] (byte*) memset::dst#2 ← phi( memset::@1/(byte*) memset::dst#4 memset::@3/(byte*) memset::dst#1 )
|
||||
[128] if((byte*) memset::dst#2!=(byte*) memset::end#0) goto memset::@3
|
||||
to:memset::@return
|
||||
memset::@return: scope:[memset] from memset memset::@2
|
||||
[129] return
|
||||
to:@return
|
||||
memset::@3: scope:[memset] from memset::@2
|
||||
[130] *((byte*) memset::dst#2) ← (byte) memset::c#7
|
||||
[131] (byte*) memset::dst#1 ← ++ (byte*) memset::dst#2
|
||||
to:memset::@2
|
||||
|
||||
(void*()) memcpy((void*) memcpy::destination , (void*) memcpy::source , (word) memcpy::num)
|
||||
memcpy: scope:[memcpy] from cscroll::@1 cscroll::@2
|
||||
[132] (void*) memcpy::destination#2 ← phi( cscroll::@1/(void*)(const nomodify byte*) CONIO_SCREEN_TEXT cscroll::@2/(void*)(const nomodify byte*) CONIO_SCREEN_COLORS )
|
||||
[132] (void*) memcpy::source#2 ← phi( cscroll::@1/(void*)(const nomodify byte*) CONIO_SCREEN_TEXT+(byte) $28 cscroll::@2/(void*)(const nomodify byte*) CONIO_SCREEN_COLORS+(byte) $28 )
|
||||
[133] (byte*) memcpy::src_end#0 ← (byte*)(void*) memcpy::source#2 + (word)(number) $19*(number) $28-(number) $28
|
||||
[134] (byte*) memcpy::src#4 ← (byte*)(void*) memcpy::source#2
|
||||
[135] (byte*) memcpy::dst#4 ← (byte*)(void*) memcpy::destination#2
|
||||
to:memcpy::@1
|
||||
memcpy::@1: scope:[memcpy] from memcpy memcpy::@2
|
||||
[136] (byte*) memcpy::dst#2 ← phi( memcpy/(byte*) memcpy::dst#4 memcpy::@2/(byte*) memcpy::dst#1 )
|
||||
[136] (byte*) memcpy::src#2 ← phi( memcpy/(byte*) memcpy::src#4 memcpy::@2/(byte*) memcpy::src#1 )
|
||||
[137] if((byte*) memcpy::src#2!=(byte*) memcpy::src_end#0) goto memcpy::@2
|
||||
to:memcpy::@return
|
||||
memcpy::@return: scope:[memcpy] from memcpy::@1
|
||||
[138] return
|
||||
to:@return
|
||||
memcpy::@2: scope:[memcpy] from memcpy::@1
|
||||
[139] *((byte*) memcpy::dst#2) ← *((byte*) memcpy::src#2)
|
||||
[140] (byte*) memcpy::dst#1 ← ++ (byte*) memcpy::dst#2
|
||||
[141] (byte*) memcpy::src#1 ← ++ (byte*) memcpy::src#2
|
||||
to:memcpy::@1
|
||||
|
||||
(void()) printf_uchar((byte) printf_uchar::uvalue , (byte) printf_uchar::format_min_length , (byte) printf_uchar::format_justify_left , (byte) printf_uchar::format_sign_always , (byte) printf_uchar::format_zero_padding , (byte) printf_uchar::format_upper_case , (byte) printf_uchar::format_radix)
|
||||
printf_uchar: scope:[printf_uchar] from line::@26 line::@28 line::@30 line::@32 line::@34 line::@36 line::@38 line::@39 line::@41 line::@43 line::@46 line::@48 line::@50 line::@52 line::@54 main::@17 main::@19 main::@21 main::@23
|
||||
[142] (byte) printf_uchar::uvalue#19 ← phi( line::@26/(byte) printf_uchar::uvalue#4 line::@28/(byte) printf_uchar::uvalue#5 line::@30/(byte) printf_uchar::uvalue#6 line::@32/(byte) printf_uchar::uvalue#7 line::@34/(byte) printf_uchar::uvalue#8 line::@36/(byte) printf_uchar::uvalue#9 line::@38/(byte) printf_uchar::uvalue#10 line::@39/(byte) printf_uchar::uvalue#11 line::@41/(byte) printf_uchar::uvalue#12 line::@43/(byte) printf_uchar::uvalue#13 line::@46/(byte) printf_uchar::uvalue#14 line::@48/(byte) printf_uchar::uvalue#15 line::@50/(byte) printf_uchar::uvalue#16 line::@52/(byte) printf_uchar::uvalue#17 line::@54/(byte) printf_uchar::uvalue#18 main::@17/(byte) printf_uchar::uvalue#0 main::@19/(byte) printf_uchar::uvalue#1 main::@21/(byte) printf_uchar::uvalue#2 main::@23/(byte) printf_uchar::uvalue#3 )
|
||||
to:printf_uchar::@1
|
||||
printf_uchar::@1: scope:[printf_uchar] from printf_uchar
|
||||
[143] *((byte*)&(struct printf_buffer_number) printf_buffer) ← (byte) 0
|
||||
[144] (byte) uctoa::value#1 ← (byte) printf_uchar::uvalue#19
|
||||
[145] call uctoa
|
||||
to:printf_uchar::@2
|
||||
printf_uchar::@2: scope:[printf_uchar] from printf_uchar::@1
|
||||
[146] (byte) printf_number_buffer::buffer_sign#0 ← *((byte*)&(struct printf_buffer_number) printf_buffer)
|
||||
[147] call printf_number_buffer
|
||||
to:printf_uchar::@return
|
||||
printf_uchar::@return: scope:[printf_uchar] from printf_uchar::@2
|
||||
[148] return
|
||||
to:@return
|
||||
|
||||
(void()) printf_number_buffer((byte) printf_number_buffer::buffer_sign , (byte*) printf_number_buffer::buffer_digits , (byte) printf_number_buffer::format_min_length , (byte) printf_number_buffer::format_justify_left , (byte) printf_number_buffer::format_sign_always , (byte) printf_number_buffer::format_zero_padding , (byte) printf_number_buffer::format_upper_case , (byte) printf_number_buffer::format_radix)
|
||||
printf_number_buffer: scope:[printf_number_buffer] from printf_uchar::@2
|
||||
[149] phi()
|
||||
to:printf_number_buffer::@4
|
||||
printf_number_buffer::@4: scope:[printf_number_buffer] from printf_number_buffer
|
||||
[150] phi()
|
||||
[151] call strlen
|
||||
[152] (word) strlen::return#2 ← (word) strlen::len#2
|
||||
to:printf_number_buffer::@9
|
||||
printf_number_buffer::@9: scope:[printf_number_buffer] from printf_number_buffer::@4
|
||||
[153] (word~) printf_number_buffer::$19 ← (word) strlen::return#2
|
||||
[154] (signed byte) printf_number_buffer::len#0 ← (signed byte)(word~) printf_number_buffer::$19
|
||||
[155] if((byte) 0==(byte) printf_number_buffer::buffer_sign#0) goto printf_number_buffer::@8
|
||||
to:printf_number_buffer::@5
|
||||
printf_number_buffer::@5: scope:[printf_number_buffer] from printf_number_buffer::@9
|
||||
[156] (signed byte) printf_number_buffer::len#1 ← ++ (signed byte) printf_number_buffer::len#0
|
||||
to:printf_number_buffer::@8
|
||||
printf_number_buffer::@8: scope:[printf_number_buffer] from printf_number_buffer::@5 printf_number_buffer::@9
|
||||
[157] (signed byte) printf_number_buffer::len#2 ← phi( printf_number_buffer::@9/(signed byte) printf_number_buffer::len#0 printf_number_buffer::@5/(signed byte) printf_number_buffer::len#1 )
|
||||
[158] (signed byte) printf_number_buffer::padding#1 ← (signed byte)(const byte) printf_number_buffer::format_min_length#0 - (signed byte) printf_number_buffer::len#2
|
||||
[159] if((signed byte) printf_number_buffer::padding#1>=(signed byte) 0) goto printf_number_buffer::@11
|
||||
to:printf_number_buffer::@1
|
||||
printf_number_buffer::@11: scope:[printf_number_buffer] from printf_number_buffer::@8
|
||||
[160] phi()
|
||||
to:printf_number_buffer::@1
|
||||
printf_number_buffer::@1: scope:[printf_number_buffer] from printf_number_buffer::@11 printf_number_buffer::@8
|
||||
[161] (signed byte) printf_number_buffer::padding#10 ← phi( printf_number_buffer::@11/(signed byte) printf_number_buffer::padding#1 printf_number_buffer::@8/(signed byte) 0 )
|
||||
to:printf_number_buffer::@2
|
||||
printf_number_buffer::@2: scope:[printf_number_buffer] from printf_number_buffer::@1
|
||||
[162] if((byte) 0==(byte) printf_number_buffer::buffer_sign#0) goto printf_number_buffer::@10
|
||||
to:printf_number_buffer::@6
|
||||
printf_number_buffer::@6: scope:[printf_number_buffer] from printf_number_buffer::@2
|
||||
[163] (byte) cputc::c#2 ← (byte) printf_number_buffer::buffer_sign#0
|
||||
[164] call cputc
|
||||
to:printf_number_buffer::@10
|
||||
printf_number_buffer::@10: scope:[printf_number_buffer] from printf_number_buffer::@2 printf_number_buffer::@6
|
||||
[165] if((signed byte) 0!=(signed byte) printf_number_buffer::padding#10) goto printf_number_buffer::@7
|
||||
to:printf_number_buffer::@3
|
||||
printf_number_buffer::@7: scope:[printf_number_buffer] from printf_number_buffer::@10
|
||||
[166] (byte) printf_padding::length#1 ← (byte)(signed byte) printf_number_buffer::padding#10
|
||||
[167] call printf_padding
|
||||
to:printf_number_buffer::@3
|
||||
printf_number_buffer::@3: scope:[printf_number_buffer] from printf_number_buffer::@10 printf_number_buffer::@7
|
||||
[168] phi()
|
||||
[169] call cputs
|
||||
to:printf_number_buffer::@return
|
||||
printf_number_buffer::@return: scope:[printf_number_buffer] from printf_number_buffer::@3
|
||||
[170] return
|
||||
to:@return
|
||||
|
||||
(void()) printf_padding((byte) printf_padding::pad , (byte) printf_padding::length)
|
||||
printf_padding: scope:[printf_padding] from printf_number_buffer::@7
|
||||
[171] phi()
|
||||
to:printf_padding::@1
|
||||
printf_padding::@1: scope:[printf_padding] from printf_padding printf_padding::@3
|
||||
[172] (byte) printf_padding::i#2 ← phi( printf_padding/(byte) 0 printf_padding::@3/(byte) printf_padding::i#1 )
|
||||
[173] if((byte) printf_padding::i#2<(byte) printf_padding::length#1) goto printf_padding::@2
|
||||
to:printf_padding::@return
|
||||
printf_padding::@return: scope:[printf_padding] from printf_padding::@1
|
||||
[174] return
|
||||
to:@return
|
||||
printf_padding::@2: scope:[printf_padding] from printf_padding::@1
|
||||
[175] phi()
|
||||
[176] call cputc
|
||||
to:printf_padding::@3
|
||||
printf_padding::@3: scope:[printf_padding] from printf_padding::@2
|
||||
[177] (byte) printf_padding::i#1 ← ++ (byte) printf_padding::i#2
|
||||
to:printf_padding::@1
|
||||
|
||||
(word()) strlen((byte*) strlen::str)
|
||||
strlen: scope:[strlen] from printf_number_buffer::@4
|
||||
[178] phi()
|
||||
to:strlen::@1
|
||||
strlen::@1: scope:[strlen] from strlen strlen::@2
|
||||
[179] (word) strlen::len#2 ← phi( strlen/(word) 0 strlen::@2/(word) strlen::len#1 )
|
||||
[179] (byte*) strlen::str#2 ← phi( strlen/(const byte*) printf_number_buffer::buffer_digits#0 strlen::@2/(byte*) strlen::str#0 )
|
||||
[180] if((byte) 0!=*((byte*) strlen::str#2)) goto strlen::@2
|
||||
to:strlen::@return
|
||||
strlen::@return: scope:[strlen] from strlen::@1
|
||||
[181] return
|
||||
to:@return
|
||||
strlen::@2: scope:[strlen] from strlen::@1
|
||||
[182] (word) strlen::len#1 ← ++ (word) strlen::len#2
|
||||
[183] (byte*) strlen::str#0 ← ++ (byte*) strlen::str#2
|
||||
to:strlen::@1
|
||||
|
||||
(void()) uctoa((byte) uctoa::value , (byte*) uctoa::buffer , (byte) uctoa::radix)
|
||||
uctoa: scope:[uctoa] from printf_uchar::@1
|
||||
[184] phi()
|
||||
to:uctoa::@1
|
||||
uctoa::@1: scope:[uctoa] from uctoa uctoa::@4
|
||||
[185] (byte*) uctoa::buffer#11 ← phi( uctoa::@4/(byte*) uctoa::buffer#14 uctoa/(byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS )
|
||||
[185] (byte) uctoa::started#2 ← phi( uctoa::@4/(byte) uctoa::started#4 uctoa/(byte) 0 )
|
||||
[185] (byte) uctoa::value#2 ← phi( uctoa::@4/(byte) uctoa::value#6 uctoa/(byte) uctoa::value#1 )
|
||||
[185] (byte) uctoa::digit#2 ← phi( uctoa::@4/(byte) uctoa::digit#1 uctoa/(byte) 0 )
|
||||
[186] if((byte) uctoa::digit#2<(byte) 2-(byte) 1) goto uctoa::@2
|
||||
to:uctoa::@3
|
||||
uctoa::@3: scope:[uctoa] from uctoa::@1
|
||||
[187] *((byte*) uctoa::buffer#11) ← *((const byte*) DIGITS + (byte) uctoa::value#2)
|
||||
[188] (byte*) uctoa::buffer#3 ← ++ (byte*) uctoa::buffer#11
|
||||
[189] *((byte*) uctoa::buffer#3) ← (byte) 0
|
||||
to:uctoa::@return
|
||||
uctoa::@return: scope:[uctoa] from uctoa::@3
|
||||
[190] return
|
||||
to:@return
|
||||
uctoa::@2: scope:[uctoa] from uctoa::@1
|
||||
[191] (byte) uctoa::digit_value#0 ← *((const byte*) RADIX_HEXADECIMAL_VALUES_CHAR + (byte) uctoa::digit#2)
|
||||
[192] if((byte) 0!=(byte) uctoa::started#2) goto uctoa::@5
|
||||
to:uctoa::@7
|
||||
uctoa::@7: scope:[uctoa] from uctoa::@2
|
||||
[193] if((byte) uctoa::value#2>=(byte) uctoa::digit_value#0) goto uctoa::@5
|
||||
to:uctoa::@4
|
||||
uctoa::@4: scope:[uctoa] from uctoa::@6 uctoa::@7
|
||||
[194] (byte*) uctoa::buffer#14 ← phi( uctoa::@7/(byte*) uctoa::buffer#11 uctoa::@6/(byte*) uctoa::buffer#4 )
|
||||
[194] (byte) uctoa::started#4 ← phi( uctoa::@7/(byte) uctoa::started#2 uctoa::@6/(byte) 1 )
|
||||
[194] (byte) uctoa::value#6 ← phi( uctoa::@7/(byte) uctoa::value#2 uctoa::@6/(byte) uctoa::value#0 )
|
||||
[195] (byte) uctoa::digit#1 ← ++ (byte) uctoa::digit#2
|
||||
to:uctoa::@1
|
||||
uctoa::@5: scope:[uctoa] from uctoa::@2 uctoa::@7
|
||||
[196] (byte*) uctoa_append::buffer#0 ← (byte*) uctoa::buffer#11
|
||||
[197] (byte) uctoa_append::value#0 ← (byte) uctoa::value#2
|
||||
[198] (byte) uctoa_append::sub#0 ← (byte) uctoa::digit_value#0
|
||||
[199] call uctoa_append
|
||||
[200] (byte) uctoa_append::return#0 ← (byte) uctoa_append::value#2
|
||||
to:uctoa::@6
|
||||
uctoa::@6: scope:[uctoa] from uctoa::@5
|
||||
[201] (byte) uctoa::value#0 ← (byte) uctoa_append::return#0
|
||||
[202] (byte*) uctoa::buffer#4 ← ++ (byte*) uctoa::buffer#11
|
||||
to:uctoa::@4
|
||||
|
||||
(byte()) uctoa_append((byte*) uctoa_append::buffer , (byte) uctoa_append::value , (byte) uctoa_append::sub)
|
||||
uctoa_append: scope:[uctoa_append] from uctoa::@5
|
||||
[203] phi()
|
||||
to:uctoa_append::@1
|
||||
uctoa_append::@1: scope:[uctoa_append] from uctoa_append uctoa_append::@2
|
||||
[204] (byte) uctoa_append::digit#2 ← phi( uctoa_append/(byte) 0 uctoa_append::@2/(byte) uctoa_append::digit#1 )
|
||||
[204] (byte) uctoa_append::value#2 ← phi( uctoa_append/(byte) uctoa_append::value#0 uctoa_append::@2/(byte) uctoa_append::value#1 )
|
||||
[205] if((byte) uctoa_append::value#2>=(byte) uctoa_append::sub#0) goto uctoa_append::@2
|
||||
to:uctoa_append::@3
|
||||
uctoa_append::@3: scope:[uctoa_append] from uctoa_append::@1
|
||||
[206] *((byte*) uctoa_append::buffer#0) ← *((const byte*) DIGITS + (byte) uctoa_append::digit#2)
|
||||
to:uctoa_append::@return
|
||||
uctoa_append::@return: scope:[uctoa_append] from uctoa_append::@3
|
||||
[207] return
|
||||
to:@return
|
||||
uctoa_append::@2: scope:[uctoa_append] from uctoa_append::@1
|
||||
[208] (byte) uctoa_append::digit#1 ← ++ (byte) uctoa_append::digit#2
|
||||
[209] (byte) uctoa_append::value#1 ← (byte) uctoa_append::value#2 - (byte) uctoa_append::sub#0
|
||||
to:uctoa_append::@1
|
||||
|
||||
(void()) gotoxy((byte) gotoxy::x , (byte) gotoxy::y)
|
||||
gotoxy: scope:[gotoxy] from line::@1 line::@11 line::@13 line::@17 line::@5 main::@15
|
||||
[210] (byte) gotoxy::x#10 ← phi( line::@1/(byte) 0 line::@11/(byte) gotoxy::x#5 line::@13/(byte) $14 line::@17/(byte) gotoxy::x#7 line::@5/(byte) 0 main::@15/(byte) 0 )
|
||||
[210] (byte) gotoxy::y#8 ← phi( line::@1/(byte) 0 line::@11/(byte) gotoxy::y#5 line::@13/(byte) $18 line::@17/(byte) gotoxy::y#7 line::@5/(byte) 1 main::@15/(byte) $18 )
|
||||
[211] if((byte) gotoxy::y#8<(byte) $19+(byte) 1) goto gotoxy::@3
|
||||
to:gotoxy::@1
|
||||
gotoxy::@3: scope:[gotoxy] from gotoxy
|
||||
[212] phi()
|
||||
to:gotoxy::@1
|
||||
gotoxy::@1: scope:[gotoxy] from gotoxy gotoxy::@3
|
||||
[213] (byte) gotoxy::y#10 ← phi( gotoxy::@3/(byte) gotoxy::y#8 gotoxy/(byte) 0 )
|
||||
[214] if((byte) gotoxy::x#10<(byte) $28) goto gotoxy::@4
|
||||
to:gotoxy::@2
|
||||
gotoxy::@4: scope:[gotoxy] from gotoxy::@1
|
||||
[215] phi()
|
||||
to:gotoxy::@2
|
||||
gotoxy::@2: scope:[gotoxy] from gotoxy::@1 gotoxy::@4
|
||||
[216] (byte) gotoxy::x#9 ← phi( gotoxy::@4/(byte) gotoxy::x#10 gotoxy::@1/(byte) 0 )
|
||||
[217] (byte) conio_cursor_x ← (byte) gotoxy::x#9
|
||||
[218] (byte) conio_cursor_y ← (byte) gotoxy::y#10
|
||||
[219] (word~) gotoxy::$8 ← (word)(byte) gotoxy::y#10
|
||||
[220] (word~) gotoxy::$9 ← (word~) gotoxy::$8 << (byte) 2
|
||||
[221] (word~) gotoxy::$10 ← (word~) gotoxy::$9 + (word~) gotoxy::$8
|
||||
[222] (word~) gotoxy::$4 ← (word~) gotoxy::$10 << (byte) 3
|
||||
[223] (word) gotoxy::offset#0 ← (word~) gotoxy::$4 + (byte) gotoxy::x#9
|
||||
[224] (byte*~) gotoxy::$6 ← (const nomodify byte*) CONIO_SCREEN_TEXT + (word) gotoxy::offset#0
|
||||
[225] (byte*) conio_cursor_text ← (byte*~) gotoxy::$6
|
||||
[226] (byte*~) gotoxy::$7 ← (const nomodify byte*) CONIO_SCREEN_COLORS + (word) gotoxy::offset#0
|
||||
[227] (byte*) conio_cursor_color ← (byte*~) gotoxy::$7
|
||||
to:gotoxy::@return
|
||||
gotoxy::@return: scope:[gotoxy] from gotoxy::@2
|
||||
[228] return
|
||||
to:@return
|
||||
|
||||
(dword()) clock()
|
||||
clock: scope:[clock] from main::@10
|
||||
[229] phi()
|
||||
to:clock::@return
|
||||
clock::@return: scope:[clock] from clock
|
||||
[230] return
|
||||
to:@return
|
||||
|
||||
(void()) line((byte*) line::canvas , (byte) line::x1 , (byte) line::y1 , (byte) line::x2 , (byte) line::y2)
|
||||
line: scope:[line] from main::@14
|
||||
[231] (byte) abs_u8::u#0 ← (byte) line::x2#0 - (byte) line::x1#0
|
||||
[232] call abs_u8
|
||||
[233] (byte) abs_u8::return#0 ← (byte) abs_u8::return#4
|
||||
to:line::@21
|
||||
line::@21: scope:[line] from line
|
||||
[234] (byte) line::dx#0 ← (byte) abs_u8::return#0
|
||||
[235] (byte) abs_u8::u#1 ← (byte) line::y2#0 - (byte) line::y1#0
|
||||
[236] call abs_u8
|
||||
[237] (byte) abs_u8::return#1 ← (byte) abs_u8::return#4
|
||||
to:line::@22
|
||||
line::@22: scope:[line] from line::@21
|
||||
[238] (byte) line::dy#0 ← (byte) abs_u8::return#1
|
||||
[239] (byte) sgn_u8::u#0 ← (byte) line::x2#0 - (byte) line::x1#0
|
||||
[240] call sgn_u8
|
||||
[241] (byte) sgn_u8::return#0 ← (byte) sgn_u8::return#4
|
||||
to:line::@23
|
||||
line::@23: scope:[line] from line::@22
|
||||
[242] (byte) line::sx#0 ← (byte) sgn_u8::return#0
|
||||
[243] (byte) sgn_u8::u#1 ← (byte) line::y2#0 - (byte) line::y1#0
|
||||
[244] call sgn_u8
|
||||
[245] (byte) sgn_u8::return#1 ← (byte) sgn_u8::return#4
|
||||
to:line::@24
|
||||
line::@24: scope:[line] from line::@23
|
||||
[246] (byte) line::sy#0 ← (byte) sgn_u8::return#1
|
||||
[247] if((byte) line::sx#0!=(byte) $ff) goto line::@1
|
||||
to:line::@3
|
||||
line::@3: scope:[line] from line::@24
|
||||
[248] (byte) line::y#1 ← ++ (byte) line::y1#0
|
||||
[249] (byte) line::y2#1 ← ++ (byte) line::y2#0
|
||||
to:line::@1
|
||||
line::@1: scope:[line] from line::@24 line::@3
|
||||
[250] (byte) line::y2#17 ← phi( line::@24/(byte) line::y2#0 line::@3/(byte) line::y2#1 )
|
||||
[250] (byte) line::plot1_y#0 ← phi( line::@24/(byte) line::y1#0 line::@3/(byte) line::y#1 )
|
||||
[251] call gotoxy
|
||||
to:line::@25
|
||||
line::@25: scope:[line] from line::@1
|
||||
[252] phi()
|
||||
[253] call cputs
|
||||
to:line::@26
|
||||
line::@26: scope:[line] from line::@25
|
||||
[254] (byte) printf_uchar::uvalue#4 ← (byte) line::dx#0
|
||||
[255] call printf_uchar
|
||||
to:line::@27
|
||||
line::@27: scope:[line] from line::@26
|
||||
[256] phi()
|
||||
[257] call cputs
|
||||
to:line::@28
|
||||
line::@28: scope:[line] from line::@27
|
||||
[258] (byte) printf_uchar::uvalue#5 ← (byte) line::dy#0
|
||||
[259] call printf_uchar
|
||||
to:line::@29
|
||||
line::@29: scope:[line] from line::@28
|
||||
[260] phi()
|
||||
[261] call cputs
|
||||
to:line::@30
|
||||
line::@30: scope:[line] from line::@29
|
||||
[262] (byte) printf_uchar::uvalue#6 ← (byte) line::sx#0
|
||||
[263] call printf_uchar
|
||||
to:line::@31
|
||||
line::@31: scope:[line] from line::@30
|
||||
[264] phi()
|
||||
[265] call cputs
|
||||
to:line::@32
|
||||
line::@32: scope:[line] from line::@31
|
||||
[266] (byte) printf_uchar::uvalue#7 ← (byte) line::sy#0
|
||||
[267] call printf_uchar
|
||||
to:line::@33
|
||||
line::@33: scope:[line] from line::@32
|
||||
[268] if((byte) line::dx#0>(byte) line::dy#0) goto line::@2
|
||||
to:line::@4
|
||||
line::@4: scope:[line] from line::@33
|
||||
[269] (byte) line::e#0 ← (byte) line::dy#0 >> (byte) 1
|
||||
to:line::@5
|
||||
line::@5: scope:[line] from line::@4
|
||||
[270] phi()
|
||||
[271] call gotoxy
|
||||
to:line::@34
|
||||
line::@34: scope:[line] from line::@5
|
||||
[272] (byte) printf_uchar::uvalue#8 ← (byte) line::x1#0
|
||||
[273] call printf_uchar
|
||||
to:line::@35
|
||||
line::@35: scope:[line] from line::@34
|
||||
[274] phi()
|
||||
[275] call cputs
|
||||
to:line::@36
|
||||
line::@36: scope:[line] from line::@35
|
||||
[276] (byte) printf_uchar::uvalue#9 ← (byte) line::plot1_y#0
|
||||
[277] call printf_uchar
|
||||
to:line::@37
|
||||
line::@37: scope:[line] from line::@36
|
||||
[278] phi()
|
||||
[279] call cputs
|
||||
to:line::@38
|
||||
line::@38: scope:[line] from line::@37
|
||||
[280] (byte) printf_uchar::uvalue#10 ← (byte) line::e#0
|
||||
[281] call printf_uchar
|
||||
to:line::plot1
|
||||
line::plot1: scope:[line] from line::@38
|
||||
[282] (byte~) line::plot1_$0 ← (byte) line::x1#0 >> (byte) 3
|
||||
[283] (byte~) line::plot1_$3 ← (byte~) line::plot1_$0 << (byte) 1
|
||||
[284] (byte*) line::plot1_column#0 ← (byte*) line::canvas#0 + *((const word*) plot_column + (byte~) line::plot1_$3)
|
||||
[285] (byte~) line::plot1_$2 ← (byte) line::x1#0 & (byte) 7
|
||||
[286] *((byte*) line::plot1_column#0 + (byte) line::plot1_y#0) ← *((byte*) line::plot1_column#0 + (byte) line::plot1_y#0) | *((const byte*) plot_bit + (byte~) line::plot1_$2)
|
||||
to:line::@6
|
||||
line::@6: scope:[line] from line::@8 line::plot1
|
||||
[287] (byte) line::print_row#10 ← phi( line::@8/(byte) line::print_row#26 line::plot1/(byte) 2 )
|
||||
[287] (byte) line::print_col#14 ← phi( line::@8/(byte) line::print_col#20 line::plot1/(byte) 0 )
|
||||
[287] (byte) line::x#18 ← phi( line::@8/(byte) line::x#22 line::plot1/(byte) line::x1#0 )
|
||||
[287] (byte) line::e#4 ← phi( line::@8/(byte) line::e#8 line::plot1/(byte) line::e#0 )
|
||||
[287] (byte) line::y#7 ← phi( line::@8/(byte) line::y#11 line::plot1/(byte) line::plot1_y#0 )
|
||||
[288] (byte) line::y#11 ← (byte) line::y#7 + (byte) line::sy#0
|
||||
[289] (byte) line::e#1 ← (byte) line::e#4 + (byte) line::dx#0
|
||||
[290] if((byte) line::dy#0<(byte) line::e#1) goto line::@7
|
||||
to:line::@10
|
||||
line::@10: scope:[line] from line::@6
|
||||
[291] phi()
|
||||
[292] call cputs
|
||||
to:line::@8
|
||||
line::@8: scope:[line] from line::@10 line::plot2
|
||||
[293] (byte) line::print_row#26 ← phi( line::@10/(byte) line::print_row#10 line::plot2/(byte) line::print_row#35 )
|
||||
[293] (byte) line::print_col#20 ← phi( line::@10/(byte) line::print_col#14 line::plot2/(byte) line::print_col#29 )
|
||||
[293] (byte) line::x#22 ← phi( line::@10/(byte) line::x#18 line::plot2/(byte) line::plot2_x#0 )
|
||||
[293] (byte) line::e#8 ← phi( line::@10/(byte) line::e#1 line::plot2/(byte) line::e#10 )
|
||||
[294] if((byte) line::y#11!=(byte) line::y2#17) goto line::@6
|
||||
to:line::@13
|
||||
line::@13: scope:[line] from line::@8
|
||||
[295] phi()
|
||||
[296] call gotoxy
|
||||
to:line::@45
|
||||
line::@45: scope:[line] from line::@13
|
||||
[297] phi()
|
||||
[298] call cputs
|
||||
to:line::@46
|
||||
line::@46: scope:[line] from line::@45
|
||||
[299] (byte) printf_uchar::uvalue#14 ← (byte) line::x#22
|
||||
[300] call printf_uchar
|
||||
to:line::@47
|
||||
line::@47: scope:[line] from line::@46
|
||||
[301] phi()
|
||||
[302] call cputs
|
||||
to:line::@48
|
||||
line::@48: scope:[line] from line::@47
|
||||
[303] (byte) printf_uchar::uvalue#15 ← (byte) line::y#11
|
||||
[304] call printf_uchar
|
||||
to:line::@49
|
||||
line::@49: scope:[line] from line::@48
|
||||
[305] phi()
|
||||
[306] call cputs
|
||||
to:line::@return
|
||||
line::@return: scope:[line] from line::@49 line::plot4
|
||||
[307] return
|
||||
to:@return
|
||||
line::@7: scope:[line] from line::@6
|
||||
[308] (byte) line::plot2_x#0 ← (byte) line::x#18 + (byte) line::sx#0
|
||||
[309] (byte) line::e#10 ← (byte) line::e#1 - (byte) line::dy#0
|
||||
[310] if((byte) line::print_col#14>=(byte)(number) $28-(number) 8) goto line::@9
|
||||
to:line::@11
|
||||
line::@11: scope:[line] from line::@7
|
||||
[311] (byte) gotoxy::x#5 ← (byte) line::print_col#14
|
||||
[312] (byte) gotoxy::y#5 ← (byte) line::print_row#10
|
||||
[313] call gotoxy
|
||||
to:line::@39
|
||||
line::@39: scope:[line] from line::@11
|
||||
[314] (byte) printf_uchar::uvalue#11 ← (byte) line::plot2_x#0
|
||||
[315] call printf_uchar
|
||||
to:line::@40
|
||||
line::@40: scope:[line] from line::@39
|
||||
[316] phi()
|
||||
[317] call cputs
|
||||
to:line::@41
|
||||
line::@41: scope:[line] from line::@40
|
||||
[318] (byte) printf_uchar::uvalue#12 ← (byte) line::y#11
|
||||
[319] call printf_uchar
|
||||
to:line::@42
|
||||
line::@42: scope:[line] from line::@41
|
||||
[320] phi()
|
||||
[321] call cputs
|
||||
to:line::@43
|
||||
line::@43: scope:[line] from line::@42
|
||||
[322] (byte) printf_uchar::uvalue#13 ← (byte) line::e#10
|
||||
[323] call printf_uchar
|
||||
to:line::@44
|
||||
line::@44: scope:[line] from line::@43
|
||||
[324] (byte) line::print_row#3 ← ++ (byte) line::print_row#10
|
||||
[325] if((byte) line::print_row#3!=(byte) $18) goto line::@9
|
||||
to:line::@12
|
||||
line::@12: scope:[line] from line::@44
|
||||
[326] (byte) line::print_col#2 ← (byte) line::print_col#14 + (byte) 9
|
||||
to:line::@9
|
||||
line::@9: scope:[line] from line::@12 line::@44 line::@7
|
||||
[327] (byte) line::print_row#35 ← phi( line::@12/(byte) 1 line::@44/(byte) line::print_row#3 line::@7/(byte) line::print_row#10 )
|
||||
[327] (byte) line::print_col#29 ← phi( line::@12/(byte) line::print_col#2 line::@44/(byte) line::print_col#14 line::@7/(byte) line::print_col#14 )
|
||||
to:line::plot2
|
||||
line::plot2: scope:[line] from line::@9
|
||||
[328] (byte~) line::plot2_$0 ← (byte) line::plot2_x#0 >> (byte) 3
|
||||
[329] (byte~) line::plot2_$3 ← (byte~) line::plot2_$0 << (byte) 1
|
||||
[330] (byte*) line::plot2_column#0 ← (byte*) line::canvas#0 + *((const word*) plot_column + (byte~) line::plot2_$3)
|
||||
[331] (byte~) line::plot2_$2 ← (byte) line::plot2_x#0 & (byte) 7
|
||||
[332] *((byte*) line::plot2_column#0 + (byte) line::y#11) ← *((byte*) line::plot2_column#0 + (byte) line::y#11) | *((const byte*) plot_bit + (byte~) line::plot2_$2)
|
||||
to:line::@8
|
||||
line::@2: scope:[line] from line::@33
|
||||
[333] (byte) line::e1#0 ← (byte) line::dx#0 >> (byte) 1
|
||||
to:line::@14
|
||||
line::@14: scope:[line] from line::@16 line::@2
|
||||
[334] (byte) line::e1#10 ← phi( line::@16/(byte) line::e1#14 line::@2/(byte) line::e1#0 )
|
||||
[334] (byte) line::print_row#11 ← phi( line::@16/(byte) line::print_row#22 line::@2/(byte) 1 )
|
||||
[334] (byte) line::y#12 ← phi( line::@16/(byte) line::y#15 line::@2/(byte) line::plot1_y#0 )
|
||||
[334] (byte) line::x#10 ← phi( line::@16/(byte) line::x#12 line::@2/(byte) line::x1#0 )
|
||||
[334] (byte) line::print_col#10 ← phi( line::@16/(byte) line::print_col#16 line::@2/(byte) 0 )
|
||||
[335] if((byte) line::print_col#10>=(byte)(number) $28-(number) 8) goto line::@15
|
||||
to:line::@17
|
||||
line::@17: scope:[line] from line::@14
|
||||
[336] (byte) gotoxy::x#7 ← (byte) line::print_col#10
|
||||
[337] (byte) gotoxy::y#7 ← (byte) line::print_row#11
|
||||
[338] call gotoxy
|
||||
to:line::@50
|
||||
line::@50: scope:[line] from line::@17
|
||||
[339] (byte) printf_uchar::uvalue#16 ← (byte) line::x#10
|
||||
[340] call printf_uchar
|
||||
to:line::@51
|
||||
line::@51: scope:[line] from line::@50
|
||||
[341] phi()
|
||||
[342] call cputs
|
||||
to:line::@52
|
||||
line::@52: scope:[line] from line::@51
|
||||
[343] (byte) printf_uchar::uvalue#17 ← (byte) line::y#12
|
||||
[344] call printf_uchar
|
||||
to:line::@53
|
||||
line::@53: scope:[line] from line::@52
|
||||
[345] phi()
|
||||
[346] call cputs
|
||||
to:line::@54
|
||||
line::@54: scope:[line] from line::@53
|
||||
[347] (byte) printf_uchar::uvalue#18 ← (byte) line::e1#10
|
||||
[348] call printf_uchar
|
||||
to:line::@55
|
||||
line::@55: scope:[line] from line::@54
|
||||
[349] (byte) line::print_row#5 ← ++ (byte) line::print_row#11
|
||||
[350] if((byte) line::print_row#5!=(byte) $18) goto line::@15
|
||||
to:line::@18
|
||||
line::@18: scope:[line] from line::@55
|
||||
[351] (byte) line::print_col#3 ← (byte) line::print_col#10 + (byte) 9
|
||||
to:line::@15
|
||||
line::@15: scope:[line] from line::@14 line::@18 line::@55
|
||||
[352] (byte) line::print_row#22 ← phi( line::@14/(byte) line::print_row#11 line::@18/(byte) 1 line::@55/(byte) line::print_row#5 )
|
||||
[352] (byte) line::print_col#16 ← phi( line::@14/(byte) line::print_col#10 line::@18/(byte) line::print_col#3 line::@55/(byte) line::print_col#10 )
|
||||
to:line::plot3
|
||||
line::plot3: scope:[line] from line::@15
|
||||
[353] (byte~) line::plot3_$0 ← (byte) line::x#10 >> (byte) 3
|
||||
[354] (byte~) line::plot3_$3 ← (byte~) line::plot3_$0 << (byte) 1
|
||||
[355] (byte*) line::plot3_column#0 ← (byte*) line::canvas#0 + *((const word*) plot_column + (byte~) line::plot3_$3)
|
||||
[356] (byte~) line::plot3_$2 ← (byte) line::x#10 & (byte) 7
|
||||
[357] *((byte*) line::plot3_column#0 + (byte) line::y#12) ← *((byte*) line::plot3_column#0 + (byte) line::y#12) | *((const byte*) plot_bit + (byte~) line::plot3_$2)
|
||||
to:line::@20
|
||||
line::@20: scope:[line] from line::plot3
|
||||
[358] (byte) line::x#12 ← (byte) line::x#10 + (byte) line::sx#0
|
||||
[359] (byte) line::e1#1 ← (byte) line::e1#10 + (byte) line::dy#0
|
||||
[360] if((byte) line::dx#0>=(byte) line::e1#1) goto line::@16
|
||||
to:line::@19
|
||||
line::@19: scope:[line] from line::@20
|
||||
[361] (byte) line::y#3 ← (byte) line::y#12 + (byte) line::sy#0
|
||||
[362] (byte) line::e1#2 ← (byte) line::e1#1 - (byte) line::dx#0
|
||||
to:line::@16
|
||||
line::@16: scope:[line] from line::@19 line::@20
|
||||
[363] (byte) line::e1#14 ← phi( line::@19/(byte) line::e1#2 line::@20/(byte) line::e1#1 )
|
||||
[363] (byte) line::y#15 ← phi( line::@19/(byte) line::y#3 line::@20/(byte) line::y#12 )
|
||||
[364] if((byte) line::x#12!=(byte) line::x2#0) goto line::@14
|
||||
to:line::plot4
|
||||
line::plot4: scope:[line] from line::@16
|
||||
[365] (byte~) line::plot4_$0 ← (byte) line::x#12 >> (byte) 3
|
||||
[366] (byte~) line::plot4_$3 ← (byte~) line::plot4_$0 << (byte) 1
|
||||
[367] (byte*) line::plot4_column#0 ← (byte*) line::canvas#0 + *((const word*) plot_column + (byte~) line::plot4_$3)
|
||||
[368] (byte~) line::plot4_$2 ← (byte) line::x#12 & (byte) 7
|
||||
[369] *((byte*) line::plot4_column#0 + (byte) line::y#15) ← *((byte*) line::plot4_column#0 + (byte) line::y#15) | *((const byte*) plot_bit + (byte~) line::plot4_$2)
|
||||
to:line::@return
|
||||
|
||||
(byte()) sgn_u8((byte) sgn_u8::u)
|
||||
sgn_u8: scope:[sgn_u8] from line::@22 line::@23
|
||||
[370] (byte) sgn_u8::u#2 ← phi( line::@22/(byte) sgn_u8::u#0 line::@23/(byte) sgn_u8::u#1 )
|
||||
[371] (byte~) sgn_u8::$0 ← (byte) sgn_u8::u#2 & (byte) $80
|
||||
[372] if((byte) 0!=(byte~) sgn_u8::$0) goto sgn_u8::@1
|
||||
to:sgn_u8::@return
|
||||
sgn_u8::@1: scope:[sgn_u8] from sgn_u8
|
||||
[373] phi()
|
||||
to:sgn_u8::@return
|
||||
sgn_u8::@return: scope:[sgn_u8] from sgn_u8 sgn_u8::@1
|
||||
[374] (byte) sgn_u8::return#4 ← phi( sgn_u8::@1/(byte) -1 sgn_u8/(byte) 1 )
|
||||
[375] return
|
||||
to:@return
|
||||
|
||||
(byte()) abs_u8((byte) abs_u8::u)
|
||||
abs_u8: scope:[abs_u8] from line line::@21
|
||||
[376] (byte) abs_u8::u#2 ← phi( line/(byte) abs_u8::u#0 line::@21/(byte) abs_u8::u#1 )
|
||||
[377] (byte~) abs_u8::$0 ← (byte) abs_u8::u#2 & (byte) $80
|
||||
[378] if((byte) 0!=(byte~) abs_u8::$0) goto abs_u8::@1
|
||||
to:abs_u8::@return
|
||||
abs_u8::@1: scope:[abs_u8] from abs_u8
|
||||
[379] (byte) abs_u8::return#2 ← - (byte) abs_u8::u#2
|
||||
to:abs_u8::@return
|
||||
abs_u8::@return: scope:[abs_u8] from abs_u8 abs_u8::@1
|
||||
[380] (byte) abs_u8::return#4 ← phi( abs_u8::@1/(byte) abs_u8::return#2 abs_u8/(byte) abs_u8::u#2 )
|
||||
[381] return
|
||||
to:@return
|
||||
|
||||
(void()) clock_start()
|
||||
clock_start: scope:[clock_start] from main::@8
|
||||
[382] *((byte*)(const nomodify struct MOS6526_CIA*) CIA2+(const byte) OFFSET_STRUCT_MOS6526_CIA_TIMER_A_CONTROL) ← (byte) 0
|
||||
[383] *((byte*)(const nomodify struct MOS6526_CIA*) CIA2+(const byte) OFFSET_STRUCT_MOS6526_CIA_TIMER_B_CONTROL) ← (const nomodify byte) CIA_TIMER_CONTROL_B_COUNT_UNDERFLOW_A
|
||||
[384] *((const nomodify dword*) CIA2_TIMER_AB) ← (dword) $ffffffff
|
||||
[385] *((byte*)(const nomodify struct MOS6526_CIA*) CIA2+(const byte) OFFSET_STRUCT_MOS6526_CIA_TIMER_B_CONTROL) ← (const nomodify byte) CIA_TIMER_CONTROL_START|(const nomodify byte) CIA_TIMER_CONTROL_B_COUNT_UNDERFLOW_A
|
||||
[386] *((byte*)(const nomodify struct MOS6526_CIA*) CIA2+(const byte) OFFSET_STRUCT_MOS6526_CIA_TIMER_A_CONTROL) ← (const nomodify byte) CIA_TIMER_CONTROL_START
|
||||
to:clock_start::@return
|
||||
clock_start::@return: scope:[clock_start] from clock_start
|
||||
[387] return
|
||||
to:@return
|
||||
|
||||
(byte()) textcolor((byte) textcolor::color)
|
||||
textcolor: scope:[textcolor] from main::@12
|
||||
[388] (byte) conio_textcolor ← (const nomodify byte) WHITE
|
||||
to:textcolor::@return
|
||||
textcolor::@return: scope:[textcolor] from textcolor
|
||||
[389] return
|
||||
to:@return
|
||||
|
||||
(void()) setup_irq()
|
||||
setup_irq: scope:[setup_irq] from main::@3
|
||||
asm { sei }
|
||||
[391] *((byte*)(const nomodify struct MOS6526_CIA*) CIA1+(const byte) OFFSET_STRUCT_MOS6526_CIA_INTERRUPT) ← (const nomodify byte) CIA_INTERRUPT_CLEAR
|
||||
[392] *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_CONTROL1) ← *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_CONTROL1) & (byte) $7f
|
||||
[393] *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_RASTER) ← (const nomodify byte) BORDER_YPOS_BOTTOM-(byte) 8
|
||||
[394] *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_IRQ_ENABLE) ← (const nomodify byte) IRQ_RASTER
|
||||
[395] *((const nomodify void()**) KERNEL_IRQ) ← &interrupt(KERNEL_MIN)(void()) irq_bottom_1()
|
||||
asm { cli }
|
||||
to:setup_irq::@return
|
||||
setup_irq::@return: scope:[setup_irq] from setup_irq
|
||||
[397] return
|
||||
to:@return
|
||||
|
||||
interrupt(KERNEL_KEYBOARD)(void()) irq_bottom_2()
|
||||
irq_bottom_2: scope:[irq_bottom_2] from
|
||||
[398] *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR) ← (const nomodify byte) BLACK
|
||||
[399] call kbhit
|
||||
[400] (byte) kbhit::return#2 ← (byte) kbhit::return#0
|
||||
to:irq_bottom_2::@3
|
||||
irq_bottom_2::@3: scope:[irq_bottom_2] from irq_bottom_2
|
||||
[401] (byte~) irq_bottom_2::$0 ← (byte) kbhit::return#2
|
||||
[402] if((byte) 0!=(byte~) irq_bottom_2::$0) goto irq_bottom_2::@1
|
||||
to:irq_bottom_2::@2
|
||||
irq_bottom_2::@2: scope:[irq_bottom_2] from irq_bottom_2::@3
|
||||
[403] *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_MEMORY) ← (volatile byte) canvas_show_memory
|
||||
to:irq_bottom_2::@1
|
||||
irq_bottom_2::@1: scope:[irq_bottom_2] from irq_bottom_2::@2 irq_bottom_2::@3
|
||||
[404] (volatile byte) canvas_show_flag ← (byte) 0
|
||||
[405] *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_IRQ_STATUS) ← (const nomodify byte) IRQ_RASTER
|
||||
[406] *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_RASTER) ← (const nomodify byte) BORDER_YPOS_BOTTOM-(byte) 8
|
||||
[407] *((const nomodify void()**) KERNEL_IRQ) ← &interrupt(KERNEL_MIN)(void()) irq_bottom_1()
|
||||
to:irq_bottom_2::@return
|
||||
irq_bottom_2::@return: scope:[irq_bottom_2] from irq_bottom_2::@1
|
||||
[408] return
|
||||
to:@return
|
||||
|
||||
(byte()) kbhit()
|
||||
kbhit: scope:[kbhit] from irq_bottom_2
|
||||
[409] *((const nomodify byte*) CONIO_CIA1_PORT_A) ← (byte) 0
|
||||
[410] (byte) kbhit::return#0 ← ~ *((const nomodify byte*) CONIO_CIA1_PORT_B)
|
||||
to:kbhit::@return
|
||||
kbhit::@return: scope:[kbhit] from kbhit
|
||||
[411] return
|
||||
to:@return
|
||||
|
||||
interrupt(KERNEL_MIN)(void()) irq_bottom_1()
|
||||
irq_bottom_1: scope:[irq_bottom_1] from
|
||||
[412] *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR) ← (const nomodify byte) WHITE
|
||||
to:irq_bottom_1::toD0181
|
||||
irq_bottom_1::toD0181: scope:[irq_bottom_1] from irq_bottom_1
|
||||
[413] phi()
|
||||
to:irq_bottom_1::@1
|
||||
irq_bottom_1::@1: scope:[irq_bottom_1] from irq_bottom_1::toD0181
|
||||
[414] *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_MEMORY) ← (const byte) irq_bottom_1::toD0181_return#0
|
||||
[415] *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_IRQ_STATUS) ← (const nomodify byte) IRQ_RASTER
|
||||
[416] *((byte*)(const nomodify struct MOS6569_VICII*) VICII+(const byte) OFFSET_STRUCT_MOS6569_VICII_RASTER) ← (const nomodify byte) BORDER_YPOS_BOTTOM
|
||||
[417] *((const nomodify void()**) KERNEL_IRQ) ← &interrupt(KERNEL_KEYBOARD)(void()) irq_bottom_2()
|
||||
to:irq_bottom_1::@return
|
||||
irq_bottom_1::@return: scope:[irq_bottom_1] from irq_bottom_1::@1
|
||||
[418] return
|
||||
to:@return
|
18692
src/test/ref/complex/polygon/polygon.log
Normal file
18692
src/test/ref/complex/polygon/polygon.log
Normal file
File diff suppressed because one or more lines are too long
756
src/test/ref/complex/polygon/polygon.sym
Normal file
756
src/test/ref/complex/polygon/polygon.sym
Normal file
@ -0,0 +1,756 @@
|
||||
(label) @1
|
||||
(label) @2
|
||||
(label) @3
|
||||
(label) @begin
|
||||
(label) @end
|
||||
(const nomodify byte) BLACK = (byte) 0
|
||||
(const nomodify byte) BORDER_YPOS_BOTTOM = (byte) $fa
|
||||
(const nomodify byte*) CANVAS1 = (byte*) 12288
|
||||
(const nomodify byte*) CANVAS2 = (byte*) 14336
|
||||
(const nomodify struct MOS6526_CIA*) CIA1 = (struct MOS6526_CIA*) 56320
|
||||
(const nomodify struct MOS6526_CIA*) CIA2 = (struct MOS6526_CIA*) 56576
|
||||
(const nomodify dword*) CIA2_TIMER_AB = (dword*) 56580
|
||||
(const nomodify byte) CIA_INTERRUPT_CLEAR = (byte) $7f
|
||||
(const nomodify byte) CIA_TIMER_CONTROL_B_COUNT_UNDERFLOW_A = (byte) $40
|
||||
(const nomodify byte) CIA_TIMER_CONTROL_START = (byte) 1
|
||||
(const nomodify byte*) COLS = (byte*) 55296
|
||||
(const nomodify byte*) CONIO_CIA1_PORT_A = (byte*) 56320
|
||||
(const nomodify byte*) CONIO_CIA1_PORT_B = (byte*) 56321
|
||||
(const nomodify byte*) CONIO_SCREEN_COLORS = (byte*) 55296
|
||||
(const nomodify byte*) CONIO_SCREEN_TEXT = (byte*) 1024
|
||||
(const nomodify byte) CONIO_TEXTCOLOR_DEFAULT = (byte) $e
|
||||
(const nomodify byte*) CONSOLE = (byte*) 1024
|
||||
(const byte*) COSTAB = (const byte*) SINTAB+(byte) $40
|
||||
(const byte*) DIGITS[] = (byte*) "0123456789abcdef"z
|
||||
(const nomodify byte) IRQ_RASTER = (byte) 1
|
||||
(const nomodify void()**) KERNEL_IRQ = (void()**) 788
|
||||
(byte) MOS6526_CIA::INTERRUPT
|
||||
(byte) MOS6526_CIA::PORT_A
|
||||
(byte) MOS6526_CIA::PORT_A_DDR
|
||||
(byte) MOS6526_CIA::PORT_B
|
||||
(byte) MOS6526_CIA::PORT_B_DDR
|
||||
(byte) MOS6526_CIA::SERIAL_DATA
|
||||
(word) MOS6526_CIA::TIMER_A
|
||||
(byte) MOS6526_CIA::TIMER_A_CONTROL
|
||||
(word) MOS6526_CIA::TIMER_B
|
||||
(byte) MOS6526_CIA::TIMER_B_CONTROL
|
||||
(byte) MOS6526_CIA::TOD_10THS
|
||||
(byte) MOS6526_CIA::TOD_HOURS
|
||||
(byte) MOS6526_CIA::TOD_MIN
|
||||
(byte) MOS6526_CIA::TOD_SEC
|
||||
(byte) MOS6569_VICII::BG_COLOR
|
||||
(byte) MOS6569_VICII::BG_COLOR1
|
||||
(byte) MOS6569_VICII::BG_COLOR2
|
||||
(byte) MOS6569_VICII::BG_COLOR3
|
||||
(byte) MOS6569_VICII::BORDER_COLOR
|
||||
(byte) MOS6569_VICII::CONTROL1
|
||||
(byte) MOS6569_VICII::CONTROL2
|
||||
(byte) MOS6569_VICII::IRQ_ENABLE
|
||||
(byte) MOS6569_VICII::IRQ_STATUS
|
||||
(byte) MOS6569_VICII::LIGHTPEN_X
|
||||
(byte) MOS6569_VICII::LIGHTPEN_Y
|
||||
(byte) MOS6569_VICII::MEMORY
|
||||
(byte) MOS6569_VICII::RASTER
|
||||
(byte) MOS6569_VICII::SPRITE0_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE0_X
|
||||
(byte) MOS6569_VICII::SPRITE0_Y
|
||||
(byte) MOS6569_VICII::SPRITE1_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE1_X
|
||||
(byte) MOS6569_VICII::SPRITE1_Y
|
||||
(byte) MOS6569_VICII::SPRITE2_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE2_X
|
||||
(byte) MOS6569_VICII::SPRITE2_Y
|
||||
(byte) MOS6569_VICII::SPRITE3_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE3_X
|
||||
(byte) MOS6569_VICII::SPRITE3_Y
|
||||
(byte) MOS6569_VICII::SPRITE4_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE4_X
|
||||
(byte) MOS6569_VICII::SPRITE4_Y
|
||||
(byte) MOS6569_VICII::SPRITE5_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE5_X
|
||||
(byte) MOS6569_VICII::SPRITE5_Y
|
||||
(byte) MOS6569_VICII::SPRITE6_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE6_X
|
||||
(byte) MOS6569_VICII::SPRITE6_Y
|
||||
(byte) MOS6569_VICII::SPRITE7_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE7_X
|
||||
(byte) MOS6569_VICII::SPRITE7_Y
|
||||
(byte) MOS6569_VICII::SPRITES_BG_COLLISION
|
||||
(byte) MOS6569_VICII::SPRITES_COLLISION
|
||||
(byte) MOS6569_VICII::SPRITES_ENABLE
|
||||
(byte) MOS6569_VICII::SPRITES_EXPAND_X
|
||||
(byte) MOS6569_VICII::SPRITES_EXPAND_Y
|
||||
(byte) MOS6569_VICII::SPRITES_MC
|
||||
(byte) MOS6569_VICII::SPRITES_MCOLOR1
|
||||
(byte) MOS6569_VICII::SPRITES_MCOLOR2
|
||||
(byte) MOS6569_VICII::SPRITES_PRIORITY
|
||||
(byte) MOS6569_VICII::SPRITES_XMSB
|
||||
(byte) MOS6581_SID::CH1_ATTACK_DECAY
|
||||
(byte) MOS6581_SID::CH1_CONTROL
|
||||
(word) MOS6581_SID::CH1_FREQ
|
||||
(word) MOS6581_SID::CH1_PULSE_WIDTH
|
||||
(byte) MOS6581_SID::CH1_SUSTAIN_RELEASE
|
||||
(byte) MOS6581_SID::CH2_ATTACK_DECAY
|
||||
(byte) MOS6581_SID::CH2_CONTROL
|
||||
(word) MOS6581_SID::CH2_FREQ
|
||||
(word) MOS6581_SID::CH2_PULSE_WIDTH
|
||||
(byte) MOS6581_SID::CH2_SUSTAIN_RELEASE
|
||||
(byte) MOS6581_SID::CH3_ATTACK_DECAY
|
||||
(byte) MOS6581_SID::CH3_CONTROL
|
||||
(byte) MOS6581_SID::CH3_ENV
|
||||
(word) MOS6581_SID::CH3_FREQ
|
||||
(byte) MOS6581_SID::CH3_OSC
|
||||
(word) MOS6581_SID::CH3_PULSE_WIDTH
|
||||
(byte) MOS6581_SID::CH3_SUSTAIN_RELEASE
|
||||
(byte) MOS6581_SID::FILTER_CUTOFF_HIGH
|
||||
(byte) MOS6581_SID::FILTER_CUTOFF_LOW
|
||||
(byte) MOS6581_SID::FILTER_SETUP
|
||||
(byte) MOS6581_SID::POT_X
|
||||
(byte) MOS6581_SID::POT_Y
|
||||
(byte) MOS6581_SID::VOLUME_FILTER_MODE
|
||||
(const byte) OFFSET_STRUCT_MOS6526_CIA_INTERRUPT = (byte) $d
|
||||
(const byte) OFFSET_STRUCT_MOS6526_CIA_TIMER_A_CONTROL = (byte) $e
|
||||
(const byte) OFFSET_STRUCT_MOS6526_CIA_TIMER_B_CONTROL = (byte) $f
|
||||
(const byte) OFFSET_STRUCT_MOS6569_VICII_BG_COLOR = (byte) $21
|
||||
(const byte) OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR = (byte) $20
|
||||
(const byte) OFFSET_STRUCT_MOS6569_VICII_CONTROL1 = (byte) $11
|
||||
(const byte) OFFSET_STRUCT_MOS6569_VICII_IRQ_ENABLE = (byte) $1a
|
||||
(const byte) OFFSET_STRUCT_MOS6569_VICII_IRQ_STATUS = (byte) $19
|
||||
(const byte) OFFSET_STRUCT_MOS6569_VICII_MEMORY = (byte) $18
|
||||
(const byte) OFFSET_STRUCT_MOS6569_VICII_RASTER = (byte) $12
|
||||
(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS = (byte) 1
|
||||
(const nomodify byte*) PETSCII = (byte*) 4096
|
||||
(const byte) RADIX::BINARY = (number) 2
|
||||
(const byte) RADIX::DECIMAL = (number) $a
|
||||
(const byte) RADIX::HEXADECIMAL = (number) $10
|
||||
(const byte) RADIX::OCTAL = (number) 8
|
||||
(const byte*) RADIX_HEXADECIMAL_VALUES_CHAR[] = { (byte) $10 }
|
||||
(const nomodify byte*) SCREEN = (byte*) 11264
|
||||
(const byte*) SINTAB[(number) $140] = kickasm {{ .fill $200, 63 + 63*sin(i*2*PI/$100)
|
||||
}}
|
||||
(const byte) SIZEOF_STRUCT_PRINTF_BUFFER_NUMBER = (byte) $c
|
||||
(const nomodify struct MOS6569_VICII*) VICII = (struct MOS6569_VICII*) 53248
|
||||
(const nomodify byte) WHITE = (byte) 1
|
||||
(byte()) abs_u8((byte) abs_u8::u)
|
||||
(byte~) abs_u8::$0 reg byte x 20002.0
|
||||
(label) abs_u8::@1
|
||||
(label) abs_u8::@return
|
||||
(byte) abs_u8::return
|
||||
(byte) abs_u8::return#0 reg byte a 2002.0
|
||||
(byte) abs_u8::return#1 reg byte a 2002.0
|
||||
(byte) abs_u8::return#2 reg byte a 20002.0
|
||||
(byte) abs_u8::return#4 reg byte a 5501.0
|
||||
(byte) abs_u8::u
|
||||
(byte) abs_u8::u#0 reg byte a 2002.0
|
||||
(byte) abs_u8::u#1 reg byte a 2002.0
|
||||
(byte) abs_u8::u#2 reg byte a 10668.333333333332
|
||||
(volatile byte) canvas_show_flag loadstore zp[1]:27 553.0
|
||||
(volatile byte) canvas_show_memory loadstore zp[1]:26 2.8611111111111107
|
||||
(dword()) clock()
|
||||
(label) clock::@return
|
||||
(dword) clock::return
|
||||
(void()) clock_start()
|
||||
(label) clock_start::@return
|
||||
(byte*) conio_cursor_color loadstore zp[2]:23 1.2185792404372131E12
|
||||
(byte*) conio_cursor_text loadstore zp[2]:21 1.205405410810865E12
|
||||
(byte) conio_cursor_x loadstore zp[1]:19 1.910112415730899E11
|
||||
(byte) conio_cursor_y loadstore zp[1]:20 1.6512820564103079E12
|
||||
(byte) conio_textcolor loadstore zp[1]:25 3.7686567164218286E11
|
||||
(void()) cputc((byte) cputc::c)
|
||||
(label) cputc::@1
|
||||
(label) cputc::@2
|
||||
(label) cputc::@3
|
||||
(label) cputc::@return
|
||||
(byte) cputc::c
|
||||
(byte) cputc::c#0 reg byte a 2.00000000002E11
|
||||
(byte) cputc::c#2 reg byte a 2.0000002E7
|
||||
(byte) cputc::c#3 reg byte a 1.050005000002E12
|
||||
(void()) cputln()
|
||||
(byte*~) cputln::$0 zp[2]:21 2.0000000000002E13
|
||||
(byte*~) cputln::$1 zp[2]:21 2.0000000000002E13
|
||||
(byte*~) cputln::$2 zp[2]:23 2.0000000000002E13
|
||||
(byte*~) cputln::$3 zp[2]:23 2.0000000000002E13
|
||||
(label) cputln::@return
|
||||
(void()) cputs((to_nomodify byte*) cputs::s)
|
||||
(label) cputs::@1
|
||||
(label) cputs::@2
|
||||
(label) cputs::@return
|
||||
(byte) cputs::c
|
||||
(byte) cputs::c#1 reg byte a 1.00000000001E11
|
||||
(to_nomodify byte*) cputs::s
|
||||
(to_nomodify byte*) cputs::s#0 s zp[2]:39 5.00000000005E10
|
||||
(to_nomodify byte*) cputs::s#21 s zp[2]:39 1.50050000002E11
|
||||
(to_nomodify byte*) cputs::s#22 s zp[2]:39 1.00000001E8
|
||||
(void()) cscroll()
|
||||
(byte*~) cscroll::$7 zp[2]:21 2.00000000000002E14
|
||||
(byte*~) cscroll::$8 zp[2]:23 2.00000000000002E14
|
||||
(label) cscroll::@1
|
||||
(label) cscroll::@2
|
||||
(label) cscroll::@3
|
||||
(label) cscroll::@4
|
||||
(label) cscroll::@5
|
||||
(label) cscroll::@return
|
||||
(void()) gotoxy((byte) gotoxy::x , (byte) gotoxy::y)
|
||||
(word~) gotoxy::$10 zp[2]:23 2000002.0
|
||||
(word~) gotoxy::$4 zp[2]:23 2000002.0
|
||||
(byte*~) gotoxy::$6 zp[2]:21 2000002.0
|
||||
(byte*~) gotoxy::$7 zp[2]:23 2000002.0
|
||||
(word~) gotoxy::$8 zp[2]:23 1500001.5
|
||||
(word~) gotoxy::$9 zp[2]:41 2000002.0
|
||||
(label) gotoxy::@1
|
||||
(label) gotoxy::@2
|
||||
(label) gotoxy::@3
|
||||
(label) gotoxy::@4
|
||||
(label) gotoxy::@return
|
||||
(word) gotoxy::offset
|
||||
(word) gotoxy::offset#0 offset zp[2]:23 1000001.0
|
||||
(byte) gotoxy::x
|
||||
(byte) gotoxy::x#10 reg byte x 366667.3333333334
|
||||
(byte) gotoxy::x#5 reg byte x 100001.0
|
||||
(byte) gotoxy::x#7 reg byte x 100001.0
|
||||
(byte) gotoxy::x#9 reg byte x 428571.85714285716
|
||||
(byte) gotoxy::y
|
||||
(byte) gotoxy::y#10 reg byte a 333333.6666666667
|
||||
(byte) gotoxy::y#5 reg byte a 200002.0
|
||||
(byte) gotoxy::y#7 reg byte a 200002.0
|
||||
(byte) gotoxy::y#8 reg byte a 733334.6666666667
|
||||
interrupt(KERNEL_MIN)(void()) irq_bottom_1()
|
||||
(label) irq_bottom_1::@1
|
||||
(label) irq_bottom_1::@return
|
||||
(label) irq_bottom_1::toD0181
|
||||
(byte*) irq_bottom_1::toD0181_gfx
|
||||
(byte) irq_bottom_1::toD0181_return
|
||||
(const byte) irq_bottom_1::toD0181_return#0 toD0181_return = >(word)(const nomodify byte*) CONSOLE&(word) $3fff*(byte) 4|>(word)(const nomodify byte*) PETSCII/(byte) 4&(byte) $f
|
||||
(byte*) irq_bottom_1::toD0181_screen
|
||||
interrupt(KERNEL_KEYBOARD)(void()) irq_bottom_2()
|
||||
(byte~) irq_bottom_2::$0 reg byte a 4.0
|
||||
(label) irq_bottom_2::@1
|
||||
(label) irq_bottom_2::@2
|
||||
(label) irq_bottom_2::@3
|
||||
(label) irq_bottom_2::@return
|
||||
(byte()) kbhit()
|
||||
(label) kbhit::@return
|
||||
(byte) kbhit::return
|
||||
(byte) kbhit::return#0 reg byte a 4.333333333333333
|
||||
(byte) kbhit::return#2 reg byte a 4.0
|
||||
(void()) line((byte*) line::canvas , (byte) line::x1 , (byte) line::y1 , (byte) line::x2 , (byte) line::y2)
|
||||
(label) line::@1
|
||||
(label) line::@10
|
||||
(label) line::@11
|
||||
(label) line::@12
|
||||
(label) line::@13
|
||||
(label) line::@14
|
||||
(label) line::@15
|
||||
(label) line::@16
|
||||
(label) line::@17
|
||||
(label) line::@18
|
||||
(label) line::@19
|
||||
(label) line::@2
|
||||
(label) line::@20
|
||||
(label) line::@21
|
||||
(label) line::@22
|
||||
(label) line::@23
|
||||
(label) line::@24
|
||||
(label) line::@25
|
||||
(label) line::@26
|
||||
(label) line::@27
|
||||
(label) line::@28
|
||||
(label) line::@29
|
||||
(label) line::@3
|
||||
(label) line::@30
|
||||
(label) line::@31
|
||||
(label) line::@32
|
||||
(label) line::@33
|
||||
(label) line::@34
|
||||
(label) line::@35
|
||||
(label) line::@36
|
||||
(label) line::@37
|
||||
(label) line::@38
|
||||
(label) line::@39
|
||||
(label) line::@4
|
||||
(label) line::@40
|
||||
(label) line::@41
|
||||
(label) line::@42
|
||||
(label) line::@43
|
||||
(label) line::@44
|
||||
(label) line::@45
|
||||
(label) line::@46
|
||||
(label) line::@47
|
||||
(label) line::@48
|
||||
(label) line::@49
|
||||
(label) line::@5
|
||||
(label) line::@50
|
||||
(label) line::@51
|
||||
(label) line::@52
|
||||
(label) line::@53
|
||||
(label) line::@54
|
||||
(label) line::@55
|
||||
(label) line::@6
|
||||
(label) line::@7
|
||||
(label) line::@8
|
||||
(label) line::@9
|
||||
(label) line::@return
|
||||
(byte*) line::canvas
|
||||
(byte*) line::canvas#0 canvas zp[2]:6 1578.9453125
|
||||
(byte) line::dx
|
||||
(byte) line::dx#0 dx zp[1]:33 2576.330508474576
|
||||
(byte) line::dy
|
||||
(byte) line::dy#0 dy zp[1]:34 2666.728070175439
|
||||
(byte) line::e
|
||||
(byte) line::e#0 e zp[1]:11 166.83333333333334
|
||||
(byte) line::e#1 e zp[1]:11 80000.8
|
||||
(byte) line::e#10 e zp[1]:11 12500.125
|
||||
(byte) line::e#4 e zp[1]:11 100501.5
|
||||
(byte) line::e#8 e zp[1]:11 150001.5
|
||||
(byte) line::e1
|
||||
(byte) line::e1#0 e1 zp[1]:18 2002.0
|
||||
(byte) line::e1#1 e1 zp[1]:18 133334.66666666666
|
||||
(byte) line::e1#10 e1 zp[1]:18 12040.16
|
||||
(byte) line::e1#14 e1 zp[1]:18 150001.5
|
||||
(byte) line::e1#2 e1 zp[1]:18 200002.0
|
||||
(label) line::plot1
|
||||
(byte~) line::plot1_$0 reg byte a 2002.0
|
||||
(byte~) line::plot1_$2 reg byte a 2002.0
|
||||
(byte~) line::plot1_$3 reg byte a 2002.0
|
||||
(byte*) line::plot1_canvas
|
||||
(byte*) line::plot1_column
|
||||
(byte*) line::plot1_column#0 plot1_column zp[2]:37 1501.5
|
||||
(byte) line::plot1_x
|
||||
(byte) line::plot1_y
|
||||
(byte) line::plot1_y#0 plot1_y zp[1]:16 184.39473684210526
|
||||
(label) line::plot2
|
||||
(byte~) line::plot2_$0 reg byte a 200002.0
|
||||
(byte~) line::plot2_$2 reg byte a 200002.0
|
||||
(byte~) line::plot2_$3 reg byte a 200002.0
|
||||
(byte*) line::plot2_canvas
|
||||
(byte*) line::plot2_column
|
||||
(byte*) line::plot2_column#0 plot2_column zp[2]:39 150001.5
|
||||
(byte) line::plot2_x
|
||||
(byte) line::plot2_x#0 plot2_x zp[1]:15 20000.2
|
||||
(byte) line::plot2_y
|
||||
(label) line::plot3
|
||||
(byte~) line::plot3_$0 reg byte a 200002.0
|
||||
(byte~) line::plot3_$2 reg byte a 200002.0
|
||||
(byte~) line::plot3_$3 reg byte a 200002.0
|
||||
(byte*) line::plot3_canvas
|
||||
(byte*) line::plot3_column
|
||||
(byte*) line::plot3_column#0 plot3_column zp[2]:41 150001.5
|
||||
(byte) line::plot3_x
|
||||
(byte) line::plot3_y
|
||||
(label) line::plot4
|
||||
(byte~) line::plot4_$0 reg byte a 2002.0
|
||||
(byte~) line::plot4_$2 reg byte a 2002.0
|
||||
(byte~) line::plot4_$3 reg byte a 2002.0
|
||||
(byte*) line::plot4_canvas
|
||||
(byte*) line::plot4_column
|
||||
(byte*) line::plot4_column#0 plot4_column zp[2]:43 1501.5
|
||||
(byte) line::plot4_x
|
||||
(byte) line::plot4_y
|
||||
(byte) line::print_col
|
||||
(byte) line::print_col#10 print_col_1 zp[1]:14 35294.470588235294
|
||||
(byte) line::print_col#14 print_col zp[1]:12 29166.95833333333
|
||||
(byte) line::print_col#16 print_col_1 zp[1]:14 30769.53846153846
|
||||
(byte) line::print_col#2 print_col zp[1]:12 200002.0
|
||||
(byte) line::print_col#20 print_col zp[1]:12 150001.5
|
||||
(byte) line::print_col#29 print_col zp[1]:12 66667.33333333333
|
||||
(byte) line::print_col#3 print_col_1 zp[1]:14 200002.0
|
||||
(byte) line::print_row
|
||||
(byte) line::print_row#10 print_row zp[1]:13 22727.5
|
||||
(byte) line::print_row#11 print_row_1 zp[1]:17 26666.933333333334
|
||||
(byte) line::print_row#22 print_row_1 zp[1]:17 23077.153846153844
|
||||
(byte) line::print_row#26 print_row zp[1]:13 150001.5
|
||||
(byte) line::print_row#3 print_row zp[1]:13 150001.5
|
||||
(byte) line::print_row#35 print_row zp[1]:13 50000.5
|
||||
(byte) line::print_row#5 print_row_1 zp[1]:17 150001.5
|
||||
(const byte*) line::s[(byte) 4] = (byte*) "dx:"
|
||||
(const byte*) line::s1[(byte) 5] = (byte*) " dy:"
|
||||
(const byte*) line::s2[(byte) 5] = (byte*) " sx:"
|
||||
(const byte*) line::s3[(byte) 5] = (byte*) " sy:"
|
||||
(const byte*) line::s4[(byte) 2] = (byte*) " "
|
||||
(const byte*) line::s6[(byte) 2] = (byte*) "*"
|
||||
(byte) line::sx
|
||||
(byte) line::sx#0 sx zp[1]:35 1845.5
|
||||
(byte) line::sy
|
||||
(byte) line::sy#0 sy zp[1]:36 1905.698113207547
|
||||
(byte) line::x
|
||||
(byte) line::x#10 x zp[1]:15 20875.249999999996
|
||||
(byte) line::x#12 x zp[1]:15 30200.5
|
||||
(byte) line::x#18 x zp[1]:15 50167.33333333333
|
||||
(byte) line::x#22 x zp[1]:15 50167.333333333336
|
||||
(byte) line::x1
|
||||
(byte) line::x1#0 x1 zp[1]:15 116.52459016393443
|
||||
(byte) line::x2
|
||||
(byte) line::x2#0 x2 zp[1]:30 1418.111111111111
|
||||
(byte) line::y
|
||||
(byte) line::y#1 y zp[1]:16 1001.0
|
||||
(byte) line::y#11 y zp[1]:16 15025.175
|
||||
(byte) line::y#12 y zp[1]:16 22259.51851851852
|
||||
(byte) line::y#15 y zp[1]:16 50334.16666666667
|
||||
(byte) line::y#3 y zp[1]:16 100001.0
|
||||
(byte) line::y#7 y zp[1]:16 201003.0
|
||||
(byte) line::y1
|
||||
(byte) line::y1#0 y1 zp[1]:16 205.25
|
||||
(byte) line::y2
|
||||
(byte) line::y2#0 y2 zp[1]:10 216.05263157894734
|
||||
(byte) line::y2#1 y2 zp[1]:10 2002.0
|
||||
(byte) line::y2#17 y2 zp[1]:10 1457.185714285714
|
||||
(void()) main()
|
||||
(label) main::@1
|
||||
(label) main::@10
|
||||
(label) main::@11
|
||||
(label) main::@12
|
||||
(label) main::@13
|
||||
(label) main::@14
|
||||
(label) main::@15
|
||||
(label) main::@16
|
||||
(label) main::@17
|
||||
(label) main::@18
|
||||
(label) main::@19
|
||||
(label) main::@2
|
||||
(label) main::@20
|
||||
(label) main::@21
|
||||
(label) main::@22
|
||||
(label) main::@23
|
||||
(label) main::@24
|
||||
(label) main::@25
|
||||
(label) main::@26
|
||||
(label) main::@3
|
||||
(label) main::@4
|
||||
(label) main::@5
|
||||
(label) main::@6
|
||||
(label) main::@7
|
||||
(label) main::@8
|
||||
(label) main::@9
|
||||
(byte) main::c
|
||||
(byte) main::c#1 reg byte x 1001.0
|
||||
(byte) main::c#2 reg byte x 776.0
|
||||
(byte) main::c#4 reg byte x 202.0
|
||||
(byte*) main::canvas
|
||||
(word) main::canvas#1 canvas zp[2]:6 4.208333333333333
|
||||
(byte*) main::canvas#10 canvas zp[2]:6 16.833333333333332
|
||||
(byte*) main::canvas#25 canvas zp[2]:6 202.0
|
||||
(byte*) main::cols
|
||||
(byte*) main::cols#1 cols zp[2]:2 67.33333333333333
|
||||
(byte*) main::cols#5 cols zp[2]:2 133.66666666666669
|
||||
(const byte) main::p0_idx = (byte) $88
|
||||
(byte) main::p1_idx
|
||||
(const byte) main::p1_idx#0 p1_idx = (const byte) main::p0_idx+(byte) $f
|
||||
(const byte*) main::s2[(byte) 4] = (byte*) ")-("
|
||||
(byte*) main::screen
|
||||
(byte*) main::screen#1 screen zp[2]:4 101.0
|
||||
(byte*) main::screen#5 screen zp[2]:4 120.3
|
||||
(label) main::toD0181
|
||||
(byte*) main::toD0181_gfx
|
||||
(byte) main::toD0181_return
|
||||
(const byte) main::toD0181_return#0 toD0181_return = >(word)(const nomodify byte*) SCREEN&(word) $3fff*(byte) 4|>(word)(const nomodify byte*) CANVAS1/(byte) 4&(byte) $f
|
||||
(byte*) main::toD0181_screen
|
||||
(label) main::toD0182
|
||||
(byte*) main::toD0182_gfx
|
||||
(byte) main::toD0182_return
|
||||
(const byte) main::toD0182_return#0 toD0182_return = >(word)(const nomodify byte*) SCREEN&(word) $3fff*(byte) 4|>(word)(const nomodify byte*) CANVAS2/(byte) 4&(byte) $f
|
||||
(byte*) main::toD0182_screen
|
||||
(byte) main::x
|
||||
(byte) main::x#1 reg byte y 2002.0
|
||||
(byte) main::x#2 reg byte y 1001.0
|
||||
(byte) main::x0
|
||||
(byte) main::x0#0 x0 zp[1]:28 15.947368421052632
|
||||
(byte) main::x1
|
||||
(byte) main::x1#0 x1 zp[1]:30 12.120000000000001
|
||||
(byte) main::y
|
||||
(byte) main::y#1 y zp[1]:19 202.0
|
||||
(byte) main::y#2 y zp[1]:19 36.72727272727273
|
||||
(byte) main::y0
|
||||
(byte) main::y0#0 y0 zp[1]:29 13.772727272727273
|
||||
(byte) main::y1
|
||||
(byte) main::y1#0 y1 zp[1]:31 10.821428571428571
|
||||
(void*()) memcpy((void*) memcpy::destination , (void*) memcpy::source , (word) memcpy::num)
|
||||
(label) memcpy::@1
|
||||
(label) memcpy::@2
|
||||
(label) memcpy::@return
|
||||
(void*) memcpy::destination
|
||||
(void*) memcpy::destination#2 destination zp[2]:37
|
||||
(byte*) memcpy::dst
|
||||
(byte*) memcpy::dst#1 dst zp[2]:37 1.0E19
|
||||
(byte*) memcpy::dst#2 dst zp[2]:37 1.0000333333333334E19
|
||||
(byte*) memcpy::dst#4 dst zp[2]:37 2.000000000000002E15
|
||||
(word) memcpy::num
|
||||
(void*) memcpy::return
|
||||
(void*) memcpy::source
|
||||
(void*) memcpy::source#2 source zp[2]:43
|
||||
(byte*) memcpy::src
|
||||
(byte*) memcpy::src#1 src zp[2]:43 2.0E19
|
||||
(byte*) memcpy::src#2 src zp[2]:43 1.000025E19
|
||||
(byte*) memcpy::src#4 src zp[2]:43 1.000000000000001E15
|
||||
(byte*) memcpy::src_end
|
||||
(byte*) memcpy::src_end#0 src_end zp[2]:41 1.250125E18
|
||||
(void*()) memset((void*) memset::str , (byte) memset::c , (word) memset::num)
|
||||
(label) memset::@1
|
||||
(label) memset::@2
|
||||
(label) memset::@3
|
||||
(label) memset::@return
|
||||
(byte) memset::c
|
||||
(byte) memset::c#1 reg byte x 2.00000000000002E14
|
||||
(byte) memset::c#7 reg byte x 1.25125E16
|
||||
(byte*) memset::dst
|
||||
(byte*) memset::dst#1 dst zp[2]:37 2.0E17
|
||||
(byte*) memset::dst#2 dst zp[2]:37 1.33666666666666656E17
|
||||
(byte*) memset::dst#4 dst zp[2]:37 2.000000000000002E15
|
||||
(byte*) memset::end
|
||||
(byte*) memset::end#0 end zp[2]:43 1.6833333333333332E16
|
||||
(word) memset::num
|
||||
(word) memset::num#5 num zp[2]:43 1.000000000000001E15
|
||||
(void*) memset::return
|
||||
(void*) memset::str
|
||||
(void*) memset::str#4 str zp[2]:37 202.0
|
||||
(void*) memset::str#6 str zp[2]:37 33.666666666666664
|
||||
(const byte*) plot_bit[] = { (byte) $80, (byte) $40, (byte) $20, (byte) $10, (byte) 8, (byte) 4, (byte) 2, (byte) 1 }
|
||||
(const word*) plot_column[] = { (word) 0, (word)(number) 1*(number) $80, (word)(number) 2*(number) $80, (word)(number) 3*(number) $80, (word)(number) 4*(number) $80, (word)(number) 5*(number) $80, (word)(number) 6*(number) $80, (word)(number) 7*(number) $80, (word)(number) 8*(number) $80, (word)(number) 9*(number) $80, (word)(number) $a*(number) $80, (word)(number) $b*(number) $80, (word)(number) $c*(number) $80, (word)(number) $d*(number) $80, (word)(number) $e*(number) $80, (word)(number) $f*(number) $80 }
|
||||
(struct printf_buffer_number) printf_buffer loadstore mem[12] = {}
|
||||
(const byte*) printf_buffer_number::digits[(number) $b] = { fill( $b, 0) }
|
||||
(byte) printf_buffer_number::sign
|
||||
(byte) printf_format_number::justify_left
|
||||
(byte) printf_format_number::min_length
|
||||
(byte) printf_format_number::radix
|
||||
(byte) printf_format_number::sign_always
|
||||
(byte) printf_format_number::upper_case
|
||||
(byte) printf_format_number::zero_padding
|
||||
(byte) printf_format_string::justify_left
|
||||
(byte) printf_format_string::min_length
|
||||
(void()) printf_number_buffer((byte) printf_number_buffer::buffer_sign , (byte*) printf_number_buffer::buffer_digits , (byte) printf_number_buffer::format_min_length , (byte) printf_number_buffer::format_justify_left , (byte) printf_number_buffer::format_sign_always , (byte) printf_number_buffer::format_zero_padding , (byte) printf_number_buffer::format_upper_case , (byte) printf_number_buffer::format_radix)
|
||||
(word~) printf_number_buffer::$19 zp[2]:43 1.0000001E7
|
||||
(label) printf_number_buffer::@1
|
||||
(label) printf_number_buffer::@10
|
||||
(label) printf_number_buffer::@11
|
||||
(label) printf_number_buffer::@2
|
||||
(label) printf_number_buffer::@3
|
||||
(label) printf_number_buffer::@4
|
||||
(label) printf_number_buffer::@5
|
||||
(label) printf_number_buffer::@6
|
||||
(label) printf_number_buffer::@7
|
||||
(label) printf_number_buffer::@8
|
||||
(label) printf_number_buffer::@9
|
||||
(label) printf_number_buffer::@return
|
||||
(struct printf_buffer_number) printf_number_buffer::buffer
|
||||
(byte*) printf_number_buffer::buffer_digits
|
||||
(const byte*) printf_number_buffer::buffer_digits#0 buffer_digits = (byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
(byte) printf_number_buffer::buffer_sign
|
||||
(byte) printf_number_buffer::buffer_sign#0 reg byte x 2066666.933333333
|
||||
(struct printf_format_number) printf_number_buffer::format
|
||||
(byte) printf_number_buffer::format_justify_left
|
||||
(byte) printf_number_buffer::format_min_length
|
||||
(const byte) printf_number_buffer::format_min_length#0 format_min_length = (byte) 2
|
||||
(byte) printf_number_buffer::format_radix
|
||||
(byte) printf_number_buffer::format_sign_always
|
||||
(byte) printf_number_buffer::format_upper_case
|
||||
(byte) printf_number_buffer::format_zero_padding
|
||||
(signed byte) printf_number_buffer::len
|
||||
(signed byte) printf_number_buffer::len#0 reg byte a 1.50000015E7
|
||||
(signed byte) printf_number_buffer::len#1 reg byte a 2.0000002E7
|
||||
(signed byte) printf_number_buffer::len#2 reg byte a 3.0000003E7
|
||||
(signed byte) printf_number_buffer::padding
|
||||
(signed byte) printf_number_buffer::padding#1 padding zp[1]:8 1.0000001E7
|
||||
(signed byte) printf_number_buffer::padding#10 padding zp[1]:8 4000000.4
|
||||
(void()) printf_padding((byte) printf_padding::pad , (byte) printf_padding::length)
|
||||
(label) printf_padding::@1
|
||||
(label) printf_padding::@2
|
||||
(label) printf_padding::@3
|
||||
(label) printf_padding::@return
|
||||
(byte) printf_padding::i
|
||||
(byte) printf_padding::i#1 i zp[1]:9 2.00000000002E11
|
||||
(byte) printf_padding::i#2 i zp[1]:9 7.500000000075E10
|
||||
(byte) printf_padding::length
|
||||
(byte) printf_padding::length#1 length zp[1]:8 1.4287142857428572E10
|
||||
(byte) printf_padding::pad
|
||||
(void()) printf_uchar((byte) printf_uchar::uvalue , (byte) printf_uchar::format_min_length , (byte) printf_uchar::format_justify_left , (byte) printf_uchar::format_sign_always , (byte) printf_uchar::format_zero_padding , (byte) printf_uchar::format_upper_case , (byte) printf_uchar::format_radix)
|
||||
(label) printf_uchar::@1
|
||||
(label) printf_uchar::@2
|
||||
(label) printf_uchar::@return
|
||||
(struct printf_format_number) printf_uchar::format
|
||||
(byte) printf_uchar::format_justify_left
|
||||
(byte) printf_uchar::format_min_length
|
||||
(byte) printf_uchar::format_radix
|
||||
(byte) printf_uchar::format_sign_always
|
||||
(byte) printf_uchar::format_upper_case
|
||||
(byte) printf_uchar::format_zero_padding
|
||||
(byte) printf_uchar::uvalue
|
||||
(byte) printf_uchar::uvalue#0 reg byte x 202.0
|
||||
(byte) printf_uchar::uvalue#1 reg byte x 202.0
|
||||
(byte) printf_uchar::uvalue#10 reg byte x 2002.0
|
||||
(byte) printf_uchar::uvalue#11 reg byte x 200002.0
|
||||
(byte) printf_uchar::uvalue#12 reg byte x 200002.0
|
||||
(byte) printf_uchar::uvalue#13 reg byte x 200002.0
|
||||
(byte) printf_uchar::uvalue#14 reg byte x 2002.0
|
||||
(byte) printf_uchar::uvalue#15 reg byte x 2002.0
|
||||
(byte) printf_uchar::uvalue#16 reg byte x 200002.0
|
||||
(byte) printf_uchar::uvalue#17 reg byte x 200002.0
|
||||
(byte) printf_uchar::uvalue#18 reg byte x 200002.0
|
||||
(byte) printf_uchar::uvalue#19 reg byte x 804710.0
|
||||
(byte) printf_uchar::uvalue#2 reg byte x 202.0
|
||||
(byte) printf_uchar::uvalue#3 reg byte x 202.0
|
||||
(byte) printf_uchar::uvalue#4 reg byte x 2002.0
|
||||
(byte) printf_uchar::uvalue#5 reg byte x 2002.0
|
||||
(byte) printf_uchar::uvalue#6 reg byte x 2002.0
|
||||
(byte) printf_uchar::uvalue#7 reg byte x 2002.0
|
||||
(byte) printf_uchar::uvalue#8 reg byte x 2002.0
|
||||
(byte) printf_uchar::uvalue#9 reg byte x 2002.0
|
||||
(const byte*) s[(byte) 2] = (byte*) "("
|
||||
(const byte*) s1[(byte) 2] = (byte*) ","
|
||||
(const byte*) s4[(byte) 2] = (byte*) ")"
|
||||
(void()) setup_irq()
|
||||
(label) setup_irq::@return
|
||||
(byte()) sgn_u8((byte) sgn_u8::u)
|
||||
(byte~) sgn_u8::$0 reg byte a 20002.0
|
||||
(label) sgn_u8::@1
|
||||
(label) sgn_u8::@return
|
||||
(byte) sgn_u8::return
|
||||
(byte) sgn_u8::return#0 reg byte a 2002.0
|
||||
(byte) sgn_u8::return#1 reg byte a 2002.0
|
||||
(byte) sgn_u8::return#4 reg byte a 500.5
|
||||
(byte) sgn_u8::u
|
||||
(byte) sgn_u8::u#0 reg byte a 2002.0
|
||||
(byte) sgn_u8::u#1 reg byte a 2002.0
|
||||
(byte) sgn_u8::u#2 reg byte a 12003.0
|
||||
(word()) strlen((byte*) strlen::str)
|
||||
(label) strlen::@1
|
||||
(label) strlen::@2
|
||||
(label) strlen::@return
|
||||
(word) strlen::len
|
||||
(word) strlen::len#1 len zp[2]:43 1.00000000001E11
|
||||
(word) strlen::len#2 len zp[2]:43 5.000250000075E10
|
||||
(word) strlen::return
|
||||
(word) strlen::return#2 return zp[2]:43 2.0000002E7
|
||||
(byte*) strlen::str
|
||||
(byte*) strlen::str#0 str zp[2]:39 2.00000000002E11
|
||||
(byte*) strlen::str#2 str zp[2]:39 1.00000000001E11
|
||||
(byte()) textcolor((byte) textcolor::color)
|
||||
(label) textcolor::@return
|
||||
(byte) textcolor::color
|
||||
(byte) textcolor::old
|
||||
(byte) textcolor::return
|
||||
(label) toD0181
|
||||
(byte*) toD0181_gfx
|
||||
(byte) toD0181_return
|
||||
(const byte) toD0181_return#0 toD0181_return = >(word)(const nomodify byte*) SCREEN&(word) $3fff*(byte) 4|>(word)(const nomodify byte*) CANVAS2/(byte) 4&(byte) $f
|
||||
(byte*) toD0181_screen
|
||||
(void()) uctoa((byte) uctoa::value , (byte*) uctoa::buffer , (byte) uctoa::radix)
|
||||
(label) uctoa::@1
|
||||
(label) uctoa::@2
|
||||
(label) uctoa::@3
|
||||
(label) uctoa::@4
|
||||
(label) uctoa::@5
|
||||
(label) uctoa::@6
|
||||
(label) uctoa::@7
|
||||
(label) uctoa::@return
|
||||
(byte*) uctoa::buffer
|
||||
(byte*) uctoa::buffer#11 buffer zp[2]:43 3.3350000004999995E9
|
||||
(byte*) uctoa::buffer#14 buffer zp[2]:43 1.50000000015E10
|
||||
(byte*) uctoa::buffer#3 buffer zp[2]:43 2.0000002E7
|
||||
(byte*) uctoa::buffer#4 buffer zp[2]:43 2.0000000002E10
|
||||
(byte) uctoa::digit
|
||||
(byte) uctoa::digit#1 digit zp[1]:8 2.0000000002E10
|
||||
(byte) uctoa::digit#2 digit zp[1]:8 3.076923077230769E9
|
||||
(byte) uctoa::digit_value
|
||||
(byte) uctoa::digit_value#0 digit_value zp[1]:32 6.0000000006E9
|
||||
(byte*) uctoa::digit_values
|
||||
(byte) uctoa::max_digits
|
||||
(byte) uctoa::radix
|
||||
(byte) uctoa::started
|
||||
(byte) uctoa::started#2 started zp[1]:9 6.0000000006E9
|
||||
(byte) uctoa::started#4 started zp[1]:9 1.0000000001E10
|
||||
(byte) uctoa::value
|
||||
(byte) uctoa::value#0 reg byte x 1.0000000001E10
|
||||
(byte) uctoa::value#1 reg byte x 5500001.0
|
||||
(byte) uctoa::value#2 reg byte x 6.670000000999999E9
|
||||
(byte) uctoa::value#6 reg byte x 1.50000000015E10
|
||||
(byte()) uctoa_append((byte*) uctoa_append::buffer , (byte) uctoa_append::value , (byte) uctoa_append::sub)
|
||||
(label) uctoa_append::@1
|
||||
(label) uctoa_append::@2
|
||||
(label) uctoa_append::@3
|
||||
(label) uctoa_append::@return
|
||||
(byte*) uctoa_append::buffer
|
||||
(byte*) uctoa_append::buffer#0 buffer zp[2]:43 1.375000000025E10
|
||||
(byte) uctoa_append::digit
|
||||
(byte) uctoa_append::digit#1 reg byte y 1.000000000000001E15
|
||||
(byte) uctoa_append::digit#2 reg byte y 1.0000500000000015E15
|
||||
(byte) uctoa_append::return
|
||||
(byte) uctoa_append::return#0 reg byte x 2.0000000002E10
|
||||
(byte) uctoa_append::sub
|
||||
(byte) uctoa_append::sub#0 sub zp[1]:32 3.333350000000005E14
|
||||
(byte) uctoa_append::value
|
||||
(byte) uctoa_append::value#0 reg byte x 3.6666666667333336E10
|
||||
(byte) uctoa_append::value#1 reg byte x 2.000000000000002E15
|
||||
(byte) uctoa_append::value#2 reg byte x 5.0001833333333425E14
|
||||
|
||||
zp[2]:2 [ main::cols#5 main::cols#1 ]
|
||||
zp[2]:4 [ main::screen#5 main::screen#1 ]
|
||||
zp[2]:6 [ main::canvas#10 main::canvas#25 main::canvas#1 line::canvas#0 ]
|
||||
reg byte y [ main::x#2 main::x#1 ]
|
||||
reg byte x [ main::c#2 main::c#4 main::c#1 ]
|
||||
reg byte a [ cputc::c#3 cputc::c#0 cputc::c#2 ]
|
||||
reg byte x [ memset::c#7 memset::c#1 ]
|
||||
reg byte x [ printf_uchar::uvalue#19 printf_uchar::uvalue#4 printf_uchar::uvalue#5 printf_uchar::uvalue#6 printf_uchar::uvalue#7 printf_uchar::uvalue#8 printf_uchar::uvalue#9 printf_uchar::uvalue#10 printf_uchar::uvalue#11 printf_uchar::uvalue#12 printf_uchar::uvalue#13 printf_uchar::uvalue#14 printf_uchar::uvalue#15 printf_uchar::uvalue#16 printf_uchar::uvalue#17 printf_uchar::uvalue#18 printf_uchar::uvalue#0 printf_uchar::uvalue#1 printf_uchar::uvalue#2 printf_uchar::uvalue#3 ]
|
||||
reg byte a [ printf_number_buffer::len#2 printf_number_buffer::len#0 printf_number_buffer::len#1 ]
|
||||
zp[1]:8 [ uctoa::digit#2 uctoa::digit#1 printf_number_buffer::padding#10 printf_number_buffer::padding#1 printf_padding::length#1 ]
|
||||
reg byte x [ uctoa::value#2 uctoa::value#6 uctoa::value#1 uctoa::value#0 ]
|
||||
zp[1]:9 [ uctoa::started#2 uctoa::started#4 printf_padding::i#2 printf_padding::i#1 ]
|
||||
reg byte x [ uctoa_append::value#2 uctoa_append::value#0 uctoa_append::value#1 ]
|
||||
reg byte y [ uctoa_append::digit#2 uctoa_append::digit#1 ]
|
||||
reg byte a [ gotoxy::y#10 gotoxy::y#8 gotoxy::y#5 gotoxy::y#7 ]
|
||||
reg byte x [ gotoxy::x#9 gotoxy::x#10 gotoxy::x#5 gotoxy::x#7 ]
|
||||
zp[1]:10 [ line::y2#17 line::y2#0 line::y2#1 ]
|
||||
zp[1]:11 [ line::e#4 line::e#8 line::e#0 line::e#1 line::e#10 ]
|
||||
zp[1]:12 [ line::print_col#14 line::print_col#20 line::print_col#29 line::print_col#2 ]
|
||||
zp[1]:13 [ line::print_row#10 line::print_row#26 line::print_row#35 line::print_row#3 ]
|
||||
zp[1]:14 [ line::print_col#10 line::print_col#16 line::print_col#3 ]
|
||||
zp[1]:15 [ line::x#10 line::x#12 line::x#18 line::x#22 line::x1#0 line::plot2_x#0 ]
|
||||
zp[1]:16 [ line::y#12 line::y#15 line::y#7 line::y#11 line::plot1_y#0 line::y1#0 line::y#1 line::y#3 ]
|
||||
zp[1]:17 [ line::print_row#11 line::print_row#22 line::print_row#5 ]
|
||||
zp[1]:18 [ line::e1#10 line::e1#14 line::e1#0 line::e1#2 line::e1#1 ]
|
||||
reg byte a [ sgn_u8::u#2 sgn_u8::u#0 sgn_u8::u#1 ]
|
||||
reg byte a [ sgn_u8::return#4 ]
|
||||
reg byte a [ abs_u8::return#4 abs_u8::return#2 abs_u8::u#2 abs_u8::u#0 abs_u8::u#1 ]
|
||||
zp[1]:19 [ conio_cursor_x main::y#2 main::y#1 ]
|
||||
zp[1]:20 [ conio_cursor_y ]
|
||||
zp[2]:21 [ conio_cursor_text cscroll::$7 cputln::$0 cputln::$1 gotoxy::$6 ]
|
||||
zp[2]:23 [ conio_cursor_color cscroll::$8 cputln::$2 cputln::$3 gotoxy::$7 gotoxy::$4 gotoxy::offset#0 gotoxy::$8 gotoxy::$10 ]
|
||||
zp[1]:25 [ conio_textcolor ]
|
||||
zp[1]:26 [ canvas_show_memory ]
|
||||
zp[1]:27 [ canvas_show_flag ]
|
||||
zp[1]:28 [ main::x0#0 ]
|
||||
zp[1]:29 [ main::y0#0 ]
|
||||
zp[1]:30 [ main::x1#0 line::x2#0 ]
|
||||
zp[1]:31 [ main::y1#0 ]
|
||||
reg byte a [ cputs::c#1 ]
|
||||
reg byte x [ printf_number_buffer::buffer_sign#0 ]
|
||||
zp[1]:32 [ uctoa::digit_value#0 uctoa_append::sub#0 ]
|
||||
reg byte x [ uctoa_append::return#0 ]
|
||||
reg byte a [ abs_u8::return#0 ]
|
||||
zp[1]:33 [ line::dx#0 ]
|
||||
reg byte a [ abs_u8::return#1 ]
|
||||
zp[1]:34 [ line::dy#0 ]
|
||||
reg byte a [ sgn_u8::return#0 ]
|
||||
zp[1]:35 [ line::sx#0 ]
|
||||
reg byte a [ sgn_u8::return#1 ]
|
||||
zp[1]:36 [ line::sy#0 ]
|
||||
reg byte a [ line::plot1_$0 ]
|
||||
reg byte a [ line::plot1_$3 ]
|
||||
zp[2]:37 [ line::plot1_column#0 memcpy::destination#2 memcpy::dst#2 memcpy::dst#4 memcpy::dst#1 memset::str#6 memset::str#4 memset::dst#2 memset::dst#4 memset::dst#1 ]
|
||||
reg byte a [ line::plot1_$2 ]
|
||||
reg byte a [ line::plot2_$0 ]
|
||||
reg byte a [ line::plot2_$3 ]
|
||||
zp[2]:39 [ line::plot2_column#0 strlen::str#2 strlen::str#0 cputs::s#21 cputs::s#22 cputs::s#0 ]
|
||||
reg byte a [ line::plot2_$2 ]
|
||||
reg byte a [ line::plot3_$0 ]
|
||||
reg byte a [ line::plot3_$3 ]
|
||||
zp[2]:41 [ line::plot3_column#0 gotoxy::$9 memcpy::src_end#0 ]
|
||||
reg byte a [ line::plot3_$2 ]
|
||||
reg byte a [ line::plot4_$0 ]
|
||||
reg byte a [ line::plot4_$3 ]
|
||||
zp[2]:43 [ line::plot4_column#0 uctoa::buffer#11 uctoa::buffer#14 uctoa::buffer#4 uctoa::buffer#3 uctoa_append::buffer#0 strlen::len#2 strlen::len#1 strlen::return#2 printf_number_buffer::$19 memcpy::source#2 memcpy::src#2 memcpy::src#4 memcpy::src#1 memset::num#5 memset::end#0 ]
|
||||
reg byte a [ line::plot4_$2 ]
|
||||
reg byte a [ sgn_u8::$0 ]
|
||||
reg byte x [ abs_u8::$0 ]
|
||||
reg byte a [ kbhit::return#2 ]
|
||||
reg byte a [ irq_bottom_2::$0 ]
|
||||
reg byte a [ kbhit::return#0 ]
|
||||
mem[12] [ printf_buffer ]
|
1221
src/test/ref/prng-xorshift.asm
Normal file
1221
src/test/ref/prng-xorshift.asm
Normal file
File diff suppressed because it is too large
Load Diff
652
src/test/ref/prng-xorshift.cfg
Normal file
652
src/test/ref/prng-xorshift.cfg
Normal file
@ -0,0 +1,652 @@
|
||||
@begin: scope:[] from
|
||||
[0] phi()
|
||||
to:@1
|
||||
@1: scope:[] from @begin
|
||||
[1] (byte) conio_cursor_x ← (byte) 0
|
||||
[2] (byte) conio_cursor_y ← (byte) 0
|
||||
[3] (byte*) conio_cursor_text ← (const nomodify byte*) CONIO_SCREEN_TEXT
|
||||
[4] (byte*) conio_cursor_color ← (const nomodify byte*) CONIO_SCREEN_COLORS
|
||||
[5] (byte) conio_textcolor ← (const nomodify byte) CONIO_TEXTCOLOR_DEFAULT
|
||||
to:@2
|
||||
@2: scope:[] from @1
|
||||
[6] phi()
|
||||
[7] call main
|
||||
to:@end
|
||||
@end: scope:[] from @2
|
||||
[8] phi()
|
||||
|
||||
(void()) main()
|
||||
main: scope:[main] from @2
|
||||
[9] phi()
|
||||
[10] call clrscr
|
||||
to:main::@6
|
||||
main::@6: scope:[main] from main
|
||||
[11] phi()
|
||||
[12] call textcolor
|
||||
to:main::@7
|
||||
main::@7: scope:[main] from main::@6
|
||||
[13] phi()
|
||||
[14] call cputs
|
||||
to:main::@8
|
||||
main::@8: scope:[main] from main::@7
|
||||
[15] phi()
|
||||
[16] call rand
|
||||
[17] (word) rand::return#0 ← (word) rand::return#2
|
||||
to:main::@9
|
||||
main::@9: scope:[main] from main::@8
|
||||
[18] (word) main::first#0 ← (word) rand::return#0
|
||||
[19] call textcolor
|
||||
to:main::@10
|
||||
main::@10: scope:[main] from main::@9
|
||||
[20] (word) main::rnd#5 ← (word) main::first#0
|
||||
to:main::@1
|
||||
main::@1: scope:[main] from main::@10 main::@11
|
||||
[21] (word) main::rnd#2 ← phi( main::@10/(word) main::rnd#5 main::@11/(word) main::rnd#1 )
|
||||
[21] (byte) main::row#3 ← phi( main::@10/(byte) 1 main::@11/(byte) main::row#7 )
|
||||
[21] (byte) main::col#3 ← phi( main::@10/(byte) 3 main::@11/(byte) main::col#7 )
|
||||
[21] (dword) main::cnt#2 ← phi( main::@10/(dword) 0 main::@11/(dword) main::cnt#1 )
|
||||
[22] (dword) main::cnt#1 ← ++ (dword) main::cnt#2
|
||||
[23] (byte~) main::$17 ← (byte)(dword) main::cnt#1
|
||||
[24] if((byte~) main::$17!=(byte) 0) goto main::@2
|
||||
to:main::@3
|
||||
main::@3: scope:[main] from main::@1
|
||||
[25] (byte) gotoxy::x#2 ← (byte) main::col#3
|
||||
[26] (byte) gotoxy::y#2 ← (byte) main::row#3
|
||||
[27] call gotoxy
|
||||
to:main::@12
|
||||
main::@12: scope:[main] from main::@3
|
||||
[28] (word) printf_uint::uvalue#0 ← (word) main::rnd#2
|
||||
[29] call printf_uint
|
||||
to:main::@13
|
||||
main::@13: scope:[main] from main::@12
|
||||
[30] (byte) main::row#1 ← ++ (byte) main::row#3
|
||||
[31] if((byte) main::row#1!=(byte) $19) goto main::@2
|
||||
to:main::@4
|
||||
main::@4: scope:[main] from main::@13
|
||||
[32] (byte) main::col#1 ← (byte) main::col#3 + (byte) 6
|
||||
[33] if((byte) main::col#1<(byte)(number) $28-(number) 5+(byte) 1) goto main::@16
|
||||
to:main::@2
|
||||
main::@16: scope:[main] from main::@4
|
||||
[34] phi()
|
||||
to:main::@2
|
||||
main::@2: scope:[main] from main::@1 main::@13 main::@16 main::@4
|
||||
[35] (byte) main::row#7 ← phi( main::@1/(byte) main::row#3 main::@13/(byte) main::row#1 main::@16/(byte) 1 main::@4/(byte) 1 )
|
||||
[35] (byte) main::col#7 ← phi( main::@1/(byte) main::col#3 main::@13/(byte) main::col#3 main::@16/(byte) main::col#1 main::@4/(byte) 3 )
|
||||
[36] call rand
|
||||
[37] (word) rand::return#1 ← (word) rand::return#2
|
||||
to:main::@11
|
||||
main::@11: scope:[main] from main::@2
|
||||
[38] (word) main::rnd#1 ← (word) rand::return#1
|
||||
[39] if((word) main::rnd#1!=(word) main::first#0) goto main::@1
|
||||
to:main::@5
|
||||
main::@5: scope:[main] from main::@11
|
||||
[40] phi()
|
||||
[41] call gotoxy
|
||||
to:main::@14
|
||||
main::@14: scope:[main] from main::@5
|
||||
[42] phi()
|
||||
[43] call cputs
|
||||
to:main::@15
|
||||
main::@15: scope:[main] from main::@14
|
||||
[44] (dword) printf_ulong::uvalue#0 ← (dword) main::cnt#1
|
||||
[45] call printf_ulong
|
||||
to:main::@return
|
||||
main::@return: scope:[main] from main::@15
|
||||
[46] return
|
||||
to:@return
|
||||
|
||||
(void()) printf_ulong((dword) printf_ulong::uvalue , (byte) printf_ulong::format_min_length , (byte) printf_ulong::format_justify_left , (byte) printf_ulong::format_sign_always , (byte) printf_ulong::format_zero_padding , (byte) printf_ulong::format_upper_case , (byte) printf_ulong::format_radix)
|
||||
printf_ulong: scope:[printf_ulong] from main::@15
|
||||
[47] phi()
|
||||
to:printf_ulong::@1
|
||||
printf_ulong::@1: scope:[printf_ulong] from printf_ulong
|
||||
[48] *((byte*)&(struct printf_buffer_number) printf_buffer) ← (byte) 0
|
||||
[49] (dword) ultoa::value#1 ← (dword) printf_ulong::uvalue#0
|
||||
[50] call ultoa
|
||||
to:printf_ulong::@2
|
||||
printf_ulong::@2: scope:[printf_ulong] from printf_ulong::@1
|
||||
[51] (byte) printf_number_buffer::buffer_sign#0 ← *((byte*)&(struct printf_buffer_number) printf_buffer)
|
||||
[52] call printf_number_buffer
|
||||
to:printf_ulong::@return
|
||||
printf_ulong::@return: scope:[printf_ulong] from printf_ulong::@2
|
||||
[53] return
|
||||
to:@return
|
||||
|
||||
(void()) printf_number_buffer((byte) printf_number_buffer::buffer_sign , (byte*) printf_number_buffer::buffer_digits , (byte) printf_number_buffer::format_min_length , (byte) printf_number_buffer::format_justify_left , (byte) printf_number_buffer::format_sign_always , (byte) printf_number_buffer::format_zero_padding , (byte) printf_number_buffer::format_upper_case , (byte) printf_number_buffer::format_radix)
|
||||
printf_number_buffer: scope:[printf_number_buffer] from printf_uint::@2 printf_ulong::@2
|
||||
[54] (byte) printf_number_buffer::format_upper_case#10 ← phi( printf_uint::@2/(const byte) printf_uint::format_upper_case#0 printf_ulong::@2/(const byte) printf_ulong::format_upper_case#0 )
|
||||
[54] (byte) printf_number_buffer::buffer_sign#10 ← phi( printf_uint::@2/(byte) printf_number_buffer::buffer_sign#1 printf_ulong::@2/(byte) printf_number_buffer::buffer_sign#0 )
|
||||
[54] (byte) printf_number_buffer::format_zero_padding#10 ← phi( printf_uint::@2/(const byte) printf_uint::format_zero_padding#0 printf_ulong::@2/(const byte) printf_ulong::format_zero_padding#0 )
|
||||
[54] (byte) printf_number_buffer::format_justify_left#10 ← phi( printf_uint::@2/(const byte) printf_uint::format_justify_left#0 printf_ulong::@2/(const byte) printf_ulong::format_justify_left#0 )
|
||||
[54] (byte) printf_number_buffer::format_min_length#2 ← phi( printf_uint::@2/(const byte) printf_uint::format_min_length#0 printf_ulong::@2/(const byte) printf_ulong::format_min_length#0 )
|
||||
[55] if((byte) 0==(byte) printf_number_buffer::format_min_length#2) goto printf_number_buffer::@1
|
||||
to:printf_number_buffer::@6
|
||||
printf_number_buffer::@6: scope:[printf_number_buffer] from printf_number_buffer
|
||||
[56] phi()
|
||||
[57] call strlen
|
||||
[58] (word) strlen::return#2 ← (word) strlen::len#2
|
||||
to:printf_number_buffer::@14
|
||||
printf_number_buffer::@14: scope:[printf_number_buffer] from printf_number_buffer::@6
|
||||
[59] (word~) printf_number_buffer::$19 ← (word) strlen::return#2
|
||||
[60] (signed byte) printf_number_buffer::len#0 ← (signed byte)(word~) printf_number_buffer::$19
|
||||
[61] if((byte) 0==(byte) printf_number_buffer::buffer_sign#10) goto printf_number_buffer::@13
|
||||
to:printf_number_buffer::@7
|
||||
printf_number_buffer::@7: scope:[printf_number_buffer] from printf_number_buffer::@14
|
||||
[62] (signed byte) printf_number_buffer::len#1 ← ++ (signed byte) printf_number_buffer::len#0
|
||||
to:printf_number_buffer::@13
|
||||
printf_number_buffer::@13: scope:[printf_number_buffer] from printf_number_buffer::@14 printf_number_buffer::@7
|
||||
[63] (signed byte) printf_number_buffer::len#2 ← phi( printf_number_buffer::@14/(signed byte) printf_number_buffer::len#0 printf_number_buffer::@7/(signed byte) printf_number_buffer::len#1 )
|
||||
[64] (signed byte) printf_number_buffer::padding#1 ← (signed byte)(byte) printf_number_buffer::format_min_length#2 - (signed byte) printf_number_buffer::len#2
|
||||
[65] if((signed byte) printf_number_buffer::padding#1>=(signed byte) 0) goto printf_number_buffer::@21
|
||||
to:printf_number_buffer::@1
|
||||
printf_number_buffer::@21: scope:[printf_number_buffer] from printf_number_buffer::@13
|
||||
[66] phi()
|
||||
to:printf_number_buffer::@1
|
||||
printf_number_buffer::@1: scope:[printf_number_buffer] from printf_number_buffer printf_number_buffer::@13 printf_number_buffer::@21
|
||||
[67] (signed byte) printf_number_buffer::padding#10 ← phi( printf_number_buffer/(signed byte) 0 printf_number_buffer::@21/(signed byte) printf_number_buffer::padding#1 printf_number_buffer::@13/(signed byte) 0 )
|
||||
[68] if((byte) 0!=(byte) printf_number_buffer::format_justify_left#10) goto printf_number_buffer::@2
|
||||
to:printf_number_buffer::@17
|
||||
printf_number_buffer::@17: scope:[printf_number_buffer] from printf_number_buffer::@1
|
||||
[69] if((byte) 0!=(byte) printf_number_buffer::format_zero_padding#10) goto printf_number_buffer::@2
|
||||
to:printf_number_buffer::@16
|
||||
printf_number_buffer::@16: scope:[printf_number_buffer] from printf_number_buffer::@17
|
||||
[70] if((signed byte) 0!=(signed byte) printf_number_buffer::padding#10) goto printf_number_buffer::@8
|
||||
to:printf_number_buffer::@2
|
||||
printf_number_buffer::@8: scope:[printf_number_buffer] from printf_number_buffer::@16
|
||||
[71] (byte) printf_padding::length#0 ← (byte)(signed byte) printf_number_buffer::padding#10
|
||||
[72] call printf_padding
|
||||
to:printf_number_buffer::@2
|
||||
printf_number_buffer::@2: scope:[printf_number_buffer] from printf_number_buffer::@1 printf_number_buffer::@16 printf_number_buffer::@17 printf_number_buffer::@8
|
||||
[73] if((byte) 0==(byte) printf_number_buffer::buffer_sign#10) goto printf_number_buffer::@3
|
||||
to:printf_number_buffer::@9
|
||||
printf_number_buffer::@9: scope:[printf_number_buffer] from printf_number_buffer::@2
|
||||
[74] (byte) cputc::c#2 ← (byte) printf_number_buffer::buffer_sign#10
|
||||
[75] call cputc
|
||||
to:printf_number_buffer::@3
|
||||
printf_number_buffer::@3: scope:[printf_number_buffer] from printf_number_buffer::@2 printf_number_buffer::@9
|
||||
[76] if((byte) 0==(byte) printf_number_buffer::format_zero_padding#10) goto printf_number_buffer::@4
|
||||
to:printf_number_buffer::@18
|
||||
printf_number_buffer::@18: scope:[printf_number_buffer] from printf_number_buffer::@3
|
||||
[77] if((signed byte) 0!=(signed byte) printf_number_buffer::padding#10) goto printf_number_buffer::@10
|
||||
to:printf_number_buffer::@4
|
||||
printf_number_buffer::@10: scope:[printf_number_buffer] from printf_number_buffer::@18
|
||||
[78] (byte) printf_padding::length#1 ← (byte)(signed byte) printf_number_buffer::padding#10
|
||||
[79] call printf_padding
|
||||
to:printf_number_buffer::@4
|
||||
printf_number_buffer::@4: scope:[printf_number_buffer] from printf_number_buffer::@10 printf_number_buffer::@18 printf_number_buffer::@3
|
||||
[80] if((byte) 0==(byte) printf_number_buffer::format_upper_case#10) goto printf_number_buffer::@5
|
||||
to:printf_number_buffer::@11
|
||||
printf_number_buffer::@11: scope:[printf_number_buffer] from printf_number_buffer::@4
|
||||
[81] phi()
|
||||
[82] call strupr
|
||||
to:printf_number_buffer::@5
|
||||
printf_number_buffer::@5: scope:[printf_number_buffer] from printf_number_buffer::@11 printf_number_buffer::@4
|
||||
[83] phi()
|
||||
[84] call cputs
|
||||
to:printf_number_buffer::@15
|
||||
printf_number_buffer::@15: scope:[printf_number_buffer] from printf_number_buffer::@5
|
||||
[85] if((byte) 0==(byte) printf_number_buffer::format_justify_left#10) goto printf_number_buffer::@return
|
||||
to:printf_number_buffer::@20
|
||||
printf_number_buffer::@20: scope:[printf_number_buffer] from printf_number_buffer::@15
|
||||
[86] if((byte) 0!=(byte) printf_number_buffer::format_zero_padding#10) goto printf_number_buffer::@return
|
||||
to:printf_number_buffer::@19
|
||||
printf_number_buffer::@19: scope:[printf_number_buffer] from printf_number_buffer::@20
|
||||
[87] if((signed byte) 0!=(signed byte) printf_number_buffer::padding#10) goto printf_number_buffer::@12
|
||||
to:printf_number_buffer::@return
|
||||
printf_number_buffer::@12: scope:[printf_number_buffer] from printf_number_buffer::@19
|
||||
[88] (byte) printf_padding::length#2 ← (byte)(signed byte) printf_number_buffer::padding#10
|
||||
[89] call printf_padding
|
||||
to:printf_number_buffer::@return
|
||||
printf_number_buffer::@return: scope:[printf_number_buffer] from printf_number_buffer::@12 printf_number_buffer::@15 printf_number_buffer::@19 printf_number_buffer::@20
|
||||
[90] return
|
||||
to:@return
|
||||
|
||||
(void()) printf_padding((byte) printf_padding::pad , (byte) printf_padding::length)
|
||||
printf_padding: scope:[printf_padding] from printf_number_buffer::@10 printf_number_buffer::@12 printf_number_buffer::@8
|
||||
[91] (byte) printf_padding::pad#5 ← phi( printf_number_buffer::@10/(byte) '0' printf_number_buffer::@12/(byte) ' ' printf_number_buffer::@8/(byte) ' ' )
|
||||
[91] (byte) printf_padding::length#4 ← phi( printf_number_buffer::@10/(byte) printf_padding::length#1 printf_number_buffer::@12/(byte) printf_padding::length#2 printf_number_buffer::@8/(byte) printf_padding::length#0 )
|
||||
to:printf_padding::@1
|
||||
printf_padding::@1: scope:[printf_padding] from printf_padding printf_padding::@3
|
||||
[92] (byte) printf_padding::i#2 ← phi( printf_padding/(byte) 0 printf_padding::@3/(byte) printf_padding::i#1 )
|
||||
[93] if((byte) printf_padding::i#2<(byte) printf_padding::length#4) goto printf_padding::@2
|
||||
to:printf_padding::@return
|
||||
printf_padding::@return: scope:[printf_padding] from printf_padding::@1
|
||||
[94] return
|
||||
to:@return
|
||||
printf_padding::@2: scope:[printf_padding] from printf_padding::@1
|
||||
[95] (byte) cputc::c#1 ← (byte) printf_padding::pad#5
|
||||
[96] call cputc
|
||||
to:printf_padding::@3
|
||||
printf_padding::@3: scope:[printf_padding] from printf_padding::@2
|
||||
[97] (byte) printf_padding::i#1 ← ++ (byte) printf_padding::i#2
|
||||
to:printf_padding::@1
|
||||
|
||||
(void()) cputc((byte) cputc::c)
|
||||
cputc: scope:[cputc] from cputs::@2 printf_number_buffer::@9 printf_padding::@2
|
||||
[98] (byte) cputc::c#3 ← phi( cputs::@2/(byte) cputc::c#0 printf_number_buffer::@9/(byte) cputc::c#2 printf_padding::@2/(byte) cputc::c#1 )
|
||||
[99] if((byte) cputc::c#3==(byte) '
|
||||
') goto cputc::@1
|
||||
to:cputc::@2
|
||||
cputc::@2: scope:[cputc] from cputc
|
||||
[100] *((byte*) conio_cursor_text) ← (byte) cputc::c#3
|
||||
[101] (byte*) conio_cursor_text ← ++ (byte*) conio_cursor_text
|
||||
[102] *((byte*) conio_cursor_color) ← (byte) conio_textcolor
|
||||
[103] (byte*) conio_cursor_color ← ++ (byte*) conio_cursor_color
|
||||
[104] (byte) conio_cursor_x ← ++ (byte) conio_cursor_x
|
||||
[105] if((byte) conio_cursor_x!=(byte) $28) goto cputc::@return
|
||||
to:cputc::@3
|
||||
cputc::@3: scope:[cputc] from cputc::@2
|
||||
[106] (byte) conio_cursor_x ← (byte) 0
|
||||
[107] (byte) conio_cursor_y ← ++ (byte) conio_cursor_y
|
||||
[108] call cscroll
|
||||
to:cputc::@return
|
||||
cputc::@return: scope:[cputc] from cputc::@1 cputc::@2 cputc::@3
|
||||
[109] return
|
||||
to:@return
|
||||
cputc::@1: scope:[cputc] from cputc
|
||||
[110] phi()
|
||||
[111] call cputln
|
||||
to:cputc::@return
|
||||
|
||||
(void()) cputln()
|
||||
cputln: scope:[cputln] from cputc::@1
|
||||
[112] (byte*~) cputln::$0 ← (byte*) conio_cursor_text - (byte) conio_cursor_x
|
||||
[113] (byte*~) cputln::$1 ← (byte*~) cputln::$0 + (byte) $28
|
||||
[114] (byte*) conio_cursor_text ← (byte*~) cputln::$1
|
||||
[115] (byte*~) cputln::$2 ← (byte*) conio_cursor_color - (byte) conio_cursor_x
|
||||
[116] (byte*~) cputln::$3 ← (byte*~) cputln::$2 + (byte) $28
|
||||
[117] (byte*) conio_cursor_color ← (byte*~) cputln::$3
|
||||
[118] (byte) conio_cursor_x ← (byte) 0
|
||||
[119] (byte) conio_cursor_y ← ++ (byte) conio_cursor_y
|
||||
[120] call cscroll
|
||||
to:cputln::@return
|
||||
cputln::@return: scope:[cputln] from cputln
|
||||
[121] return
|
||||
to:@return
|
||||
|
||||
(void()) cscroll()
|
||||
cscroll: scope:[cscroll] from cputc::@3 cputln
|
||||
[122] if((byte) conio_cursor_y!=(byte) $19) goto cscroll::@return
|
||||
to:cscroll::@1
|
||||
cscroll::@1: scope:[cscroll] from cscroll
|
||||
[123] phi()
|
||||
[124] call memcpy
|
||||
to:cscroll::@2
|
||||
cscroll::@2: scope:[cscroll] from cscroll::@1
|
||||
[125] phi()
|
||||
[126] call memcpy
|
||||
to:cscroll::@3
|
||||
cscroll::@3: scope:[cscroll] from cscroll::@2
|
||||
[127] phi()
|
||||
[128] call memset
|
||||
to:cscroll::@4
|
||||
cscroll::@4: scope:[cscroll] from cscroll::@3
|
||||
[129] (byte) memset::c#1 ← (byte) conio_textcolor
|
||||
[130] call memset
|
||||
to:cscroll::@5
|
||||
cscroll::@5: scope:[cscroll] from cscroll::@4
|
||||
[131] (byte*~) cscroll::$7 ← (byte*) conio_cursor_text - (byte) $28
|
||||
[132] (byte*) conio_cursor_text ← (byte*~) cscroll::$7
|
||||
[133] (byte*~) cscroll::$8 ← (byte*) conio_cursor_color - (byte) $28
|
||||
[134] (byte*) conio_cursor_color ← (byte*~) cscroll::$8
|
||||
[135] (byte) conio_cursor_y ← -- (byte) conio_cursor_y
|
||||
to:cscroll::@return
|
||||
cscroll::@return: scope:[cscroll] from cscroll cscroll::@5
|
||||
[136] return
|
||||
to:@return
|
||||
|
||||
(void*()) memset((void*) memset::str , (byte) memset::c , (word) memset::num)
|
||||
memset: scope:[memset] from cscroll::@3 cscroll::@4
|
||||
[137] (byte) memset::c#4 ← phi( cscroll::@3/(byte) ' ' cscroll::@4/(byte) memset::c#1 )
|
||||
[137] (void*) memset::str#3 ← phi( cscroll::@3/(void*)(const nomodify byte*) CONIO_SCREEN_TEXT+(word)(number) $19*(number) $28-(byte) $28 cscroll::@4/(void*)(const nomodify byte*) CONIO_SCREEN_COLORS+(word)(number) $19*(number) $28-(byte) $28 )
|
||||
to:memset::@1
|
||||
memset::@1: scope:[memset] from memset
|
||||
[138] (byte*) memset::end#0 ← (byte*)(void*) memset::str#3 + (byte) $28
|
||||
[139] (byte*) memset::dst#4 ← (byte*)(void*) memset::str#3
|
||||
to:memset::@2
|
||||
memset::@2: scope:[memset] from memset::@1 memset::@3
|
||||
[140] (byte*) memset::dst#2 ← phi( memset::@1/(byte*) memset::dst#4 memset::@3/(byte*) memset::dst#1 )
|
||||
[141] if((byte*) memset::dst#2!=(byte*) memset::end#0) goto memset::@3
|
||||
to:memset::@return
|
||||
memset::@return: scope:[memset] from memset::@2
|
||||
[142] return
|
||||
to:@return
|
||||
memset::@3: scope:[memset] from memset::@2
|
||||
[143] *((byte*) memset::dst#2) ← (byte) memset::c#4
|
||||
[144] (byte*) memset::dst#1 ← ++ (byte*) memset::dst#2
|
||||
to:memset::@2
|
||||
|
||||
(void*()) memcpy((void*) memcpy::destination , (void*) memcpy::source , (word) memcpy::num)
|
||||
memcpy: scope:[memcpy] from cscroll::@1 cscroll::@2
|
||||
[145] (void*) memcpy::destination#2 ← phi( cscroll::@1/(void*)(const nomodify byte*) CONIO_SCREEN_TEXT cscroll::@2/(void*)(const nomodify byte*) CONIO_SCREEN_COLORS )
|
||||
[145] (void*) memcpy::source#2 ← phi( cscroll::@1/(void*)(const nomodify byte*) CONIO_SCREEN_TEXT+(byte) $28 cscroll::@2/(void*)(const nomodify byte*) CONIO_SCREEN_COLORS+(byte) $28 )
|
||||
[146] (byte*) memcpy::src_end#0 ← (byte*)(void*) memcpy::source#2 + (word)(number) $19*(number) $28-(number) $28
|
||||
[147] (byte*) memcpy::src#4 ← (byte*)(void*) memcpy::source#2
|
||||
[148] (byte*) memcpy::dst#4 ← (byte*)(void*) memcpy::destination#2
|
||||
to:memcpy::@1
|
||||
memcpy::@1: scope:[memcpy] from memcpy memcpy::@2
|
||||
[149] (byte*) memcpy::dst#2 ← phi( memcpy/(byte*) memcpy::dst#4 memcpy::@2/(byte*) memcpy::dst#1 )
|
||||
[149] (byte*) memcpy::src#2 ← phi( memcpy/(byte*) memcpy::src#4 memcpy::@2/(byte*) memcpy::src#1 )
|
||||
[150] if((byte*) memcpy::src#2!=(byte*) memcpy::src_end#0) goto memcpy::@2
|
||||
to:memcpy::@return
|
||||
memcpy::@return: scope:[memcpy] from memcpy::@1
|
||||
[151] return
|
||||
to:@return
|
||||
memcpy::@2: scope:[memcpy] from memcpy::@1
|
||||
[152] *((byte*) memcpy::dst#2) ← *((byte*) memcpy::src#2)
|
||||
[153] (byte*) memcpy::dst#1 ← ++ (byte*) memcpy::dst#2
|
||||
[154] (byte*) memcpy::src#1 ← ++ (byte*) memcpy::src#2
|
||||
to:memcpy::@1
|
||||
|
||||
(void()) cputs((to_nomodify byte*) cputs::s)
|
||||
cputs: scope:[cputs] from main::@14 main::@7 printf_number_buffer::@5
|
||||
[155] (to_nomodify byte*) cputs::s#5 ← phi( main::@14/(const byte*) main::s1 main::@7/(const byte*) main::s printf_number_buffer::@5/(byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS )
|
||||
to:cputs::@1
|
||||
cputs::@1: scope:[cputs] from cputs cputs::@2
|
||||
[156] (to_nomodify byte*) cputs::s#4 ← phi( cputs/(to_nomodify byte*) cputs::s#5 cputs::@2/(to_nomodify byte*) cputs::s#0 )
|
||||
[157] (byte) cputs::c#1 ← *((to_nomodify byte*) cputs::s#4)
|
||||
[158] (to_nomodify byte*) cputs::s#0 ← ++ (to_nomodify byte*) cputs::s#4
|
||||
[159] if((byte) 0!=(byte) cputs::c#1) goto cputs::@2
|
||||
to:cputs::@return
|
||||
cputs::@return: scope:[cputs] from cputs::@1
|
||||
[160] return
|
||||
to:@return
|
||||
cputs::@2: scope:[cputs] from cputs::@1
|
||||
[161] (byte) cputc::c#0 ← (byte) cputs::c#1
|
||||
[162] call cputc
|
||||
to:cputs::@1
|
||||
|
||||
(byte*()) strupr((byte*) strupr::str)
|
||||
strupr: scope:[strupr] from printf_number_buffer::@11
|
||||
[163] phi()
|
||||
to:strupr::@1
|
||||
strupr::@1: scope:[strupr] from strupr strupr::@3
|
||||
[164] (byte*) strupr::src#2 ← phi( strupr/(const byte*) strupr::str#0 strupr::@3/(byte*) strupr::src#1 )
|
||||
[165] if((byte) 0!=*((byte*) strupr::src#2)) goto strupr::@2
|
||||
to:strupr::@return
|
||||
strupr::@return: scope:[strupr] from strupr::@1
|
||||
[166] return
|
||||
to:@return
|
||||
strupr::@2: scope:[strupr] from strupr::@1
|
||||
[167] (byte) toupper::ch#0 ← *((byte*) strupr::src#2)
|
||||
[168] call toupper
|
||||
[169] (byte) toupper::return#3 ← (byte) toupper::return#2
|
||||
to:strupr::@3
|
||||
strupr::@3: scope:[strupr] from strupr::@2
|
||||
[170] (byte~) strupr::$0 ← (byte) toupper::return#3
|
||||
[171] *((byte*) strupr::src#2) ← (byte~) strupr::$0
|
||||
[172] (byte*) strupr::src#1 ← ++ (byte*) strupr::src#2
|
||||
to:strupr::@1
|
||||
|
||||
(byte()) toupper((byte) toupper::ch)
|
||||
toupper: scope:[toupper] from strupr::@2
|
||||
[173] if((byte) toupper::ch#0<(byte) 'a') goto toupper::@return
|
||||
to:toupper::@2
|
||||
toupper::@2: scope:[toupper] from toupper
|
||||
[174] if((byte) toupper::ch#0<=(byte) 'z') goto toupper::@1
|
||||
to:toupper::@return
|
||||
toupper::@1: scope:[toupper] from toupper::@2
|
||||
[175] (byte) toupper::return#0 ← (byte) toupper::ch#0 + (byte) 'A'-(byte) 'a'
|
||||
to:toupper::@return
|
||||
toupper::@return: scope:[toupper] from toupper toupper::@1 toupper::@2
|
||||
[176] (byte) toupper::return#2 ← phi( toupper::@1/(byte) toupper::return#0 toupper/(byte) toupper::ch#0 toupper::@2/(byte) toupper::ch#0 )
|
||||
[177] return
|
||||
to:@return
|
||||
|
||||
(word()) strlen((byte*) strlen::str)
|
||||
strlen: scope:[strlen] from printf_number_buffer::@6
|
||||
[178] phi()
|
||||
to:strlen::@1
|
||||
strlen::@1: scope:[strlen] from strlen strlen::@2
|
||||
[179] (word) strlen::len#2 ← phi( strlen/(word) 0 strlen::@2/(word) strlen::len#1 )
|
||||
[179] (byte*) strlen::str#2 ← phi( strlen/(byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS strlen::@2/(byte*) strlen::str#0 )
|
||||
[180] if((byte) 0!=*((byte*) strlen::str#2)) goto strlen::@2
|
||||
to:strlen::@return
|
||||
strlen::@return: scope:[strlen] from strlen::@1
|
||||
[181] return
|
||||
to:@return
|
||||
strlen::@2: scope:[strlen] from strlen::@1
|
||||
[182] (word) strlen::len#1 ← ++ (word) strlen::len#2
|
||||
[183] (byte*) strlen::str#0 ← ++ (byte*) strlen::str#2
|
||||
to:strlen::@1
|
||||
|
||||
(void()) ultoa((dword) ultoa::value , (byte*) ultoa::buffer , (byte) ultoa::radix)
|
||||
ultoa: scope:[ultoa] from printf_ulong::@1
|
||||
[184] phi()
|
||||
to:ultoa::@1
|
||||
ultoa::@1: scope:[ultoa] from ultoa ultoa::@4
|
||||
[185] (byte*) ultoa::buffer#11 ← phi( ultoa::@4/(byte*) ultoa::buffer#14 ultoa/(byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS )
|
||||
[185] (byte) ultoa::started#2 ← phi( ultoa::@4/(byte) ultoa::started#4 ultoa/(byte) 0 )
|
||||
[185] (dword) ultoa::value#2 ← phi( ultoa::@4/(dword) ultoa::value#6 ultoa/(dword) ultoa::value#1 )
|
||||
[185] (byte) ultoa::digit#2 ← phi( ultoa::@4/(byte) ultoa::digit#1 ultoa/(byte) 0 )
|
||||
[186] if((byte) ultoa::digit#2<(const byte) ultoa::max_digits#1-(byte) 1) goto ultoa::@2
|
||||
to:ultoa::@3
|
||||
ultoa::@3: scope:[ultoa] from ultoa::@1
|
||||
[187] (byte~) ultoa::$11 ← (byte)(dword) ultoa::value#2
|
||||
[188] *((byte*) ultoa::buffer#11) ← *((const byte*) DIGITS + (byte~) ultoa::$11)
|
||||
[189] (byte*) ultoa::buffer#3 ← ++ (byte*) ultoa::buffer#11
|
||||
[190] *((byte*) ultoa::buffer#3) ← (byte) 0
|
||||
to:ultoa::@return
|
||||
ultoa::@return: scope:[ultoa] from ultoa::@3
|
||||
[191] return
|
||||
to:@return
|
||||
ultoa::@2: scope:[ultoa] from ultoa::@1
|
||||
[192] (byte~) ultoa::$10 ← (byte) ultoa::digit#2 << (byte) 2
|
||||
[193] (dword) ultoa::digit_value#0 ← *((const dword*) RADIX_DECIMAL_VALUES_LONG + (byte~) ultoa::$10)
|
||||
[194] if((byte) 0!=(byte) ultoa::started#2) goto ultoa::@5
|
||||
to:ultoa::@7
|
||||
ultoa::@7: scope:[ultoa] from ultoa::@2
|
||||
[195] if((dword) ultoa::value#2>=(dword) ultoa::digit_value#0) goto ultoa::@5
|
||||
to:ultoa::@4
|
||||
ultoa::@4: scope:[ultoa] from ultoa::@6 ultoa::@7
|
||||
[196] (byte*) ultoa::buffer#14 ← phi( ultoa::@7/(byte*) ultoa::buffer#11 ultoa::@6/(byte*) ultoa::buffer#4 )
|
||||
[196] (byte) ultoa::started#4 ← phi( ultoa::@7/(byte) ultoa::started#2 ultoa::@6/(byte) 1 )
|
||||
[196] (dword) ultoa::value#6 ← phi( ultoa::@7/(dword) ultoa::value#2 ultoa::@6/(dword) ultoa::value#0 )
|
||||
[197] (byte) ultoa::digit#1 ← ++ (byte) ultoa::digit#2
|
||||
to:ultoa::@1
|
||||
ultoa::@5: scope:[ultoa] from ultoa::@2 ultoa::@7
|
||||
[198] (byte*) ultoa_append::buffer#0 ← (byte*) ultoa::buffer#11
|
||||
[199] (dword) ultoa_append::value#0 ← (dword) ultoa::value#2
|
||||
[200] (dword) ultoa_append::sub#0 ← (dword) ultoa::digit_value#0
|
||||
[201] call ultoa_append
|
||||
[202] (dword) ultoa_append::return#0 ← (dword) ultoa_append::value#2
|
||||
to:ultoa::@6
|
||||
ultoa::@6: scope:[ultoa] from ultoa::@5
|
||||
[203] (dword) ultoa::value#0 ← (dword) ultoa_append::return#0
|
||||
[204] (byte*) ultoa::buffer#4 ← ++ (byte*) ultoa::buffer#11
|
||||
to:ultoa::@4
|
||||
|
||||
(dword()) ultoa_append((byte*) ultoa_append::buffer , (dword) ultoa_append::value , (dword) ultoa_append::sub)
|
||||
ultoa_append: scope:[ultoa_append] from ultoa::@5
|
||||
[205] phi()
|
||||
to:ultoa_append::@1
|
||||
ultoa_append::@1: scope:[ultoa_append] from ultoa_append ultoa_append::@2
|
||||
[206] (byte) ultoa_append::digit#2 ← phi( ultoa_append/(byte) 0 ultoa_append::@2/(byte) ultoa_append::digit#1 )
|
||||
[206] (dword) ultoa_append::value#2 ← phi( ultoa_append/(dword) ultoa_append::value#0 ultoa_append::@2/(dword) ultoa_append::value#1 )
|
||||
[207] if((dword) ultoa_append::value#2>=(dword) ultoa_append::sub#0) goto ultoa_append::@2
|
||||
to:ultoa_append::@3
|
||||
ultoa_append::@3: scope:[ultoa_append] from ultoa_append::@1
|
||||
[208] *((byte*) ultoa_append::buffer#0) ← *((const byte*) DIGITS + (byte) ultoa_append::digit#2)
|
||||
to:ultoa_append::@return
|
||||
ultoa_append::@return: scope:[ultoa_append] from ultoa_append::@3
|
||||
[209] return
|
||||
to:@return
|
||||
ultoa_append::@2: scope:[ultoa_append] from ultoa_append::@1
|
||||
[210] (byte) ultoa_append::digit#1 ← ++ (byte) ultoa_append::digit#2
|
||||
[211] (dword) ultoa_append::value#1 ← (dword) ultoa_append::value#2 - (dword) ultoa_append::sub#0
|
||||
to:ultoa_append::@1
|
||||
|
||||
(void()) gotoxy((byte) gotoxy::x , (byte) gotoxy::y)
|
||||
gotoxy: scope:[gotoxy] from main::@3 main::@5
|
||||
[212] (byte) gotoxy::x#4 ← phi( main::@3/(byte) gotoxy::x#2 main::@5/(byte) $1c )
|
||||
[212] (byte) gotoxy::y#4 ← phi( main::@3/(byte) gotoxy::y#2 main::@5/(byte) 0 )
|
||||
[213] if((byte) gotoxy::y#4<(byte) $19+(byte) 1) goto gotoxy::@3
|
||||
to:gotoxy::@1
|
||||
gotoxy::@3: scope:[gotoxy] from gotoxy
|
||||
[214] phi()
|
||||
to:gotoxy::@1
|
||||
gotoxy::@1: scope:[gotoxy] from gotoxy gotoxy::@3
|
||||
[215] (byte) gotoxy::y#5 ← phi( gotoxy::@3/(byte) gotoxy::y#4 gotoxy/(byte) 0 )
|
||||
[216] if((byte) gotoxy::x#4<(byte) $28) goto gotoxy::@4
|
||||
to:gotoxy::@2
|
||||
gotoxy::@4: scope:[gotoxy] from gotoxy::@1
|
||||
[217] phi()
|
||||
to:gotoxy::@2
|
||||
gotoxy::@2: scope:[gotoxy] from gotoxy::@1 gotoxy::@4
|
||||
[218] (byte) gotoxy::x#5 ← phi( gotoxy::@4/(byte) gotoxy::x#4 gotoxy::@1/(byte) 0 )
|
||||
[219] (byte) conio_cursor_x ← (byte) gotoxy::x#5
|
||||
[220] (byte) conio_cursor_y ← (byte) gotoxy::y#5
|
||||
[221] (word~) gotoxy::$8 ← (word)(byte) gotoxy::y#5
|
||||
[222] (word~) gotoxy::$9 ← (word~) gotoxy::$8 << (byte) 2
|
||||
[223] (word~) gotoxy::$10 ← (word~) gotoxy::$9 + (word~) gotoxy::$8
|
||||
[224] (word~) gotoxy::$4 ← (word~) gotoxy::$10 << (byte) 3
|
||||
[225] (word) gotoxy::offset#0 ← (word~) gotoxy::$4 + (byte) gotoxy::x#5
|
||||
[226] (byte*~) gotoxy::$6 ← (const nomodify byte*) CONIO_SCREEN_TEXT + (word) gotoxy::offset#0
|
||||
[227] (byte*) conio_cursor_text ← (byte*~) gotoxy::$6
|
||||
[228] (byte*~) gotoxy::$7 ← (const nomodify byte*) CONIO_SCREEN_COLORS + (word) gotoxy::offset#0
|
||||
[229] (byte*) conio_cursor_color ← (byte*~) gotoxy::$7
|
||||
to:gotoxy::@return
|
||||
gotoxy::@return: scope:[gotoxy] from gotoxy::@2
|
||||
[230] return
|
||||
to:@return
|
||||
|
||||
(word()) rand()
|
||||
rand: scope:[rand] from main::@2 main::@8
|
||||
[231] (word) rand_state#12 ← phi( main::@2/(word) rand_state#13 main::@8/(word) 1 )
|
||||
[232] (word~) rand::$0 ← (word) rand_state#12 << (byte) 7
|
||||
[233] (word) rand_state#4 ← (word) rand_state#12 ^ (word~) rand::$0
|
||||
[234] (word~) rand::$1 ← (word) rand_state#4 >> (byte) 9
|
||||
[235] (word) rand_state#5 ← (word) rand_state#4 ^ (word~) rand::$1
|
||||
[236] (word~) rand::$2 ← (word) rand_state#5 << (byte) 8
|
||||
[237] (word) rand_state#13 ← (word) rand_state#5 ^ (word~) rand::$2
|
||||
[238] (word) rand::return#2 ← (word) rand_state#13
|
||||
to:rand::@return
|
||||
rand::@return: scope:[rand] from rand
|
||||
[239] return
|
||||
to:@return
|
||||
|
||||
(void()) printf_uint((word) printf_uint::uvalue , (byte) printf_uint::format_min_length , (byte) printf_uint::format_justify_left , (byte) printf_uint::format_sign_always , (byte) printf_uint::format_zero_padding , (byte) printf_uint::format_upper_case , (byte) printf_uint::format_radix)
|
||||
printf_uint: scope:[printf_uint] from main::@12
|
||||
[240] phi()
|
||||
to:printf_uint::@1
|
||||
printf_uint::@1: scope:[printf_uint] from printf_uint
|
||||
[241] *((byte*)&(struct printf_buffer_number) printf_buffer) ← (byte) 0
|
||||
[242] (word) utoa::value#1 ← (word) printf_uint::uvalue#0
|
||||
[243] call utoa
|
||||
to:printf_uint::@2
|
||||
printf_uint::@2: scope:[printf_uint] from printf_uint::@1
|
||||
[244] (byte) printf_number_buffer::buffer_sign#1 ← *((byte*)&(struct printf_buffer_number) printf_buffer)
|
||||
[245] call printf_number_buffer
|
||||
to:printf_uint::@return
|
||||
printf_uint::@return: scope:[printf_uint] from printf_uint::@2
|
||||
[246] return
|
||||
to:@return
|
||||
|
||||
(void()) utoa((word) utoa::value , (byte*) utoa::buffer , (byte) utoa::radix)
|
||||
utoa: scope:[utoa] from printf_uint::@1
|
||||
[247] phi()
|
||||
to:utoa::@1
|
||||
utoa::@1: scope:[utoa] from utoa utoa::@4
|
||||
[248] (byte*) utoa::buffer#11 ← phi( utoa::@4/(byte*) utoa::buffer#14 utoa/(byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS )
|
||||
[248] (byte) utoa::started#2 ← phi( utoa::@4/(byte) utoa::started#4 utoa/(byte) 0 )
|
||||
[248] (word) utoa::value#2 ← phi( utoa::@4/(word) utoa::value#6 utoa/(word) utoa::value#1 )
|
||||
[248] (byte) utoa::digit#2 ← phi( utoa::@4/(byte) utoa::digit#1 utoa/(byte) 0 )
|
||||
[249] if((byte) utoa::digit#2<(const byte) utoa::max_digits#1-(byte) 1) goto utoa::@2
|
||||
to:utoa::@3
|
||||
utoa::@3: scope:[utoa] from utoa::@1
|
||||
[250] (byte~) utoa::$11 ← (byte)(word) utoa::value#2
|
||||
[251] *((byte*) utoa::buffer#11) ← *((const byte*) DIGITS + (byte~) utoa::$11)
|
||||
[252] (byte*) utoa::buffer#3 ← ++ (byte*) utoa::buffer#11
|
||||
[253] *((byte*) utoa::buffer#3) ← (byte) 0
|
||||
to:utoa::@return
|
||||
utoa::@return: scope:[utoa] from utoa::@3
|
||||
[254] return
|
||||
to:@return
|
||||
utoa::@2: scope:[utoa] from utoa::@1
|
||||
[255] (byte~) utoa::$10 ← (byte) utoa::digit#2 << (byte) 1
|
||||
[256] (word) utoa::digit_value#0 ← *((const word*) RADIX_DECIMAL_VALUES + (byte~) utoa::$10)
|
||||
[257] if((byte) 0!=(byte) utoa::started#2) goto utoa::@5
|
||||
to:utoa::@7
|
||||
utoa::@7: scope:[utoa] from utoa::@2
|
||||
[258] if((word) utoa::value#2>=(word) utoa::digit_value#0) goto utoa::@5
|
||||
to:utoa::@4
|
||||
utoa::@4: scope:[utoa] from utoa::@6 utoa::@7
|
||||
[259] (byte*) utoa::buffer#14 ← phi( utoa::@7/(byte*) utoa::buffer#11 utoa::@6/(byte*) utoa::buffer#4 )
|
||||
[259] (byte) utoa::started#4 ← phi( utoa::@7/(byte) utoa::started#2 utoa::@6/(byte) 1 )
|
||||
[259] (word) utoa::value#6 ← phi( utoa::@7/(word) utoa::value#2 utoa::@6/(word) utoa::value#0 )
|
||||
[260] (byte) utoa::digit#1 ← ++ (byte) utoa::digit#2
|
||||
to:utoa::@1
|
||||
utoa::@5: scope:[utoa] from utoa::@2 utoa::@7
|
||||
[261] (byte*) utoa_append::buffer#0 ← (byte*) utoa::buffer#11
|
||||
[262] (word) utoa_append::value#0 ← (word) utoa::value#2
|
||||
[263] (word) utoa_append::sub#0 ← (word) utoa::digit_value#0
|
||||
[264] call utoa_append
|
||||
[265] (word) utoa_append::return#0 ← (word) utoa_append::value#2
|
||||
to:utoa::@6
|
||||
utoa::@6: scope:[utoa] from utoa::@5
|
||||
[266] (word) utoa::value#0 ← (word) utoa_append::return#0
|
||||
[267] (byte*) utoa::buffer#4 ← ++ (byte*) utoa::buffer#11
|
||||
to:utoa::@4
|
||||
|
||||
(word()) utoa_append((byte*) utoa_append::buffer , (word) utoa_append::value , (word) utoa_append::sub)
|
||||
utoa_append: scope:[utoa_append] from utoa::@5
|
||||
[268] phi()
|
||||
to:utoa_append::@1
|
||||
utoa_append::@1: scope:[utoa_append] from utoa_append utoa_append::@2
|
||||
[269] (byte) utoa_append::digit#2 ← phi( utoa_append/(byte) 0 utoa_append::@2/(byte) utoa_append::digit#1 )
|
||||
[269] (word) utoa_append::value#2 ← phi( utoa_append/(word) utoa_append::value#0 utoa_append::@2/(word) utoa_append::value#1 )
|
||||
[270] if((word) utoa_append::value#2>=(word) utoa_append::sub#0) goto utoa_append::@2
|
||||
to:utoa_append::@3
|
||||
utoa_append::@3: scope:[utoa_append] from utoa_append::@1
|
||||
[271] *((byte*) utoa_append::buffer#0) ← *((const byte*) DIGITS + (byte) utoa_append::digit#2)
|
||||
to:utoa_append::@return
|
||||
utoa_append::@return: scope:[utoa_append] from utoa_append::@3
|
||||
[272] return
|
||||
to:@return
|
||||
utoa_append::@2: scope:[utoa_append] from utoa_append::@1
|
||||
[273] (byte) utoa_append::digit#1 ← ++ (byte) utoa_append::digit#2
|
||||
[274] (word) utoa_append::value#1 ← (word) utoa_append::value#2 - (word) utoa_append::sub#0
|
||||
to:utoa_append::@1
|
||||
|
||||
(byte()) textcolor((byte) textcolor::color)
|
||||
textcolor: scope:[textcolor] from main::@6 main::@9
|
||||
[275] (byte) textcolor::color#2 ← phi( main::@9/(const nomodify byte) LIGHT_BLUE main::@6/(const nomodify byte) WHITE )
|
||||
[276] (byte) conio_textcolor ← (byte) textcolor::color#2
|
||||
to:textcolor::@return
|
||||
textcolor::@return: scope:[textcolor] from textcolor
|
||||
[277] return
|
||||
to:@return
|
||||
|
||||
(void()) clrscr()
|
||||
clrscr: scope:[clrscr] from main
|
||||
[278] phi()
|
||||
to:clrscr::@1
|
||||
clrscr::@1: scope:[clrscr] from clrscr clrscr::@5
|
||||
[279] (byte*) clrscr::line_cols#5 ← phi( clrscr/(const nomodify byte*) CONIO_SCREEN_COLORS clrscr::@5/(byte*) clrscr::line_cols#1 )
|
||||
[279] (byte*) clrscr::line_text#5 ← phi( clrscr/(const nomodify byte*) CONIO_SCREEN_TEXT clrscr::@5/(byte*) clrscr::line_text#1 )
|
||||
[279] (byte) clrscr::l#2 ← phi( clrscr/(byte) 0 clrscr::@5/(byte) clrscr::l#1 )
|
||||
[280] if((byte) clrscr::l#2<(byte) $19) goto clrscr::@3
|
||||
to:clrscr::@2
|
||||
clrscr::@2: scope:[clrscr] from clrscr::@1
|
||||
[281] (byte) conio_cursor_x ← (byte) 0
|
||||
[282] (byte) conio_cursor_y ← (byte) 0
|
||||
[283] (byte*) conio_cursor_text ← (const nomodify byte*) CONIO_SCREEN_TEXT
|
||||
[284] (byte*) conio_cursor_color ← (const nomodify byte*) CONIO_SCREEN_COLORS
|
||||
to:clrscr::@return
|
||||
clrscr::@return: scope:[clrscr] from clrscr::@2
|
||||
[285] return
|
||||
to:@return
|
||||
clrscr::@3: scope:[clrscr] from clrscr::@1 clrscr::@4
|
||||
[286] (byte) clrscr::c#2 ← phi( clrscr::@1/(byte) 0 clrscr::@4/(byte) clrscr::c#1 )
|
||||
[287] if((byte) clrscr::c#2<(byte) $28) goto clrscr::@4
|
||||
to:clrscr::@5
|
||||
clrscr::@5: scope:[clrscr] from clrscr::@3
|
||||
[288] (byte*) clrscr::line_text#1 ← (byte*) clrscr::line_text#5 + (byte) $28
|
||||
[289] (byte*) clrscr::line_cols#1 ← (byte*) clrscr::line_cols#5 + (byte) $28
|
||||
[290] (byte) clrscr::l#1 ← ++ (byte) clrscr::l#2
|
||||
to:clrscr::@1
|
||||
clrscr::@4: scope:[clrscr] from clrscr::@3
|
||||
[291] *((byte*) clrscr::line_text#5 + (byte) clrscr::c#2) ← (byte) ' '
|
||||
[292] *((byte*) clrscr::line_cols#5 + (byte) clrscr::c#2) ← (byte) conio_textcolor
|
||||
[293] (byte) clrscr::c#1 ← ++ (byte) clrscr::c#2
|
||||
to:clrscr::@3
|
12583
src/test/ref/prng-xorshift.log
Normal file
12583
src/test/ref/prng-xorshift.log
Normal file
File diff suppressed because one or more lines are too long
571
src/test/ref/prng-xorshift.sym
Normal file
571
src/test/ref/prng-xorshift.sym
Normal file
@ -0,0 +1,571 @@
|
||||
(label) @1
|
||||
(label) @2
|
||||
(label) @begin
|
||||
(label) @end
|
||||
(const nomodify byte*) CONIO_SCREEN_COLORS = (byte*) 55296
|
||||
(const nomodify byte*) CONIO_SCREEN_TEXT = (byte*) 1024
|
||||
(const nomodify byte) CONIO_TEXTCOLOR_DEFAULT = (byte) $e
|
||||
(const byte*) DIGITS[] = (byte*) "0123456789abcdef"z
|
||||
(const nomodify byte) LIGHT_BLUE = (byte) $e
|
||||
(byte) MOS6526_CIA::INTERRUPT
|
||||
(byte) MOS6526_CIA::PORT_A
|
||||
(byte) MOS6526_CIA::PORT_A_DDR
|
||||
(byte) MOS6526_CIA::PORT_B
|
||||
(byte) MOS6526_CIA::PORT_B_DDR
|
||||
(byte) MOS6526_CIA::SERIAL_DATA
|
||||
(word) MOS6526_CIA::TIMER_A
|
||||
(byte) MOS6526_CIA::TIMER_A_CONTROL
|
||||
(word) MOS6526_CIA::TIMER_B
|
||||
(byte) MOS6526_CIA::TIMER_B_CONTROL
|
||||
(byte) MOS6526_CIA::TOD_10THS
|
||||
(byte) MOS6526_CIA::TOD_HOURS
|
||||
(byte) MOS6526_CIA::TOD_MIN
|
||||
(byte) MOS6526_CIA::TOD_SEC
|
||||
(byte) MOS6569_VICII::BG_COLOR
|
||||
(byte) MOS6569_VICII::BG_COLOR1
|
||||
(byte) MOS6569_VICII::BG_COLOR2
|
||||
(byte) MOS6569_VICII::BG_COLOR3
|
||||
(byte) MOS6569_VICII::BORDER_COLOR
|
||||
(byte) MOS6569_VICII::CONTROL1
|
||||
(byte) MOS6569_VICII::CONTROL2
|
||||
(byte) MOS6569_VICII::IRQ_ENABLE
|
||||
(byte) MOS6569_VICII::IRQ_STATUS
|
||||
(byte) MOS6569_VICII::LIGHTPEN_X
|
||||
(byte) MOS6569_VICII::LIGHTPEN_Y
|
||||
(byte) MOS6569_VICII::MEMORY
|
||||
(byte) MOS6569_VICII::RASTER
|
||||
(byte) MOS6569_VICII::SPRITE0_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE0_X
|
||||
(byte) MOS6569_VICII::SPRITE0_Y
|
||||
(byte) MOS6569_VICII::SPRITE1_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE1_X
|
||||
(byte) MOS6569_VICII::SPRITE1_Y
|
||||
(byte) MOS6569_VICII::SPRITE2_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE2_X
|
||||
(byte) MOS6569_VICII::SPRITE2_Y
|
||||
(byte) MOS6569_VICII::SPRITE3_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE3_X
|
||||
(byte) MOS6569_VICII::SPRITE3_Y
|
||||
(byte) MOS6569_VICII::SPRITE4_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE4_X
|
||||
(byte) MOS6569_VICII::SPRITE4_Y
|
||||
(byte) MOS6569_VICII::SPRITE5_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE5_X
|
||||
(byte) MOS6569_VICII::SPRITE5_Y
|
||||
(byte) MOS6569_VICII::SPRITE6_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE6_X
|
||||
(byte) MOS6569_VICII::SPRITE6_Y
|
||||
(byte) MOS6569_VICII::SPRITE7_COLOR
|
||||
(byte) MOS6569_VICII::SPRITE7_X
|
||||
(byte) MOS6569_VICII::SPRITE7_Y
|
||||
(byte) MOS6569_VICII::SPRITES_BG_COLLISION
|
||||
(byte) MOS6569_VICII::SPRITES_COLLISION
|
||||
(byte) MOS6569_VICII::SPRITES_ENABLE
|
||||
(byte) MOS6569_VICII::SPRITES_EXPAND_X
|
||||
(byte) MOS6569_VICII::SPRITES_EXPAND_Y
|
||||
(byte) MOS6569_VICII::SPRITES_MC
|
||||
(byte) MOS6569_VICII::SPRITES_MCOLOR1
|
||||
(byte) MOS6569_VICII::SPRITES_MCOLOR2
|
||||
(byte) MOS6569_VICII::SPRITES_PRIORITY
|
||||
(byte) MOS6569_VICII::SPRITES_XMSB
|
||||
(byte) MOS6581_SID::CH1_ATTACK_DECAY
|
||||
(byte) MOS6581_SID::CH1_CONTROL
|
||||
(word) MOS6581_SID::CH1_FREQ
|
||||
(word) MOS6581_SID::CH1_PULSE_WIDTH
|
||||
(byte) MOS6581_SID::CH1_SUSTAIN_RELEASE
|
||||
(byte) MOS6581_SID::CH2_ATTACK_DECAY
|
||||
(byte) MOS6581_SID::CH2_CONTROL
|
||||
(word) MOS6581_SID::CH2_FREQ
|
||||
(word) MOS6581_SID::CH2_PULSE_WIDTH
|
||||
(byte) MOS6581_SID::CH2_SUSTAIN_RELEASE
|
||||
(byte) MOS6581_SID::CH3_ATTACK_DECAY
|
||||
(byte) MOS6581_SID::CH3_CONTROL
|
||||
(byte) MOS6581_SID::CH3_ENV
|
||||
(word) MOS6581_SID::CH3_FREQ
|
||||
(byte) MOS6581_SID::CH3_OSC
|
||||
(word) MOS6581_SID::CH3_PULSE_WIDTH
|
||||
(byte) MOS6581_SID::CH3_SUSTAIN_RELEASE
|
||||
(byte) MOS6581_SID::FILTER_CUTOFF_HIGH
|
||||
(byte) MOS6581_SID::FILTER_CUTOFF_LOW
|
||||
(byte) MOS6581_SID::FILTER_SETUP
|
||||
(byte) MOS6581_SID::POT_X
|
||||
(byte) MOS6581_SID::POT_Y
|
||||
(byte) MOS6581_SID::VOLUME_FILTER_MODE
|
||||
(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS = (byte) 1
|
||||
(const byte) RADIX::BINARY = (number) 2
|
||||
(const byte) RADIX::DECIMAL = (number) $a
|
||||
(const byte) RADIX::HEXADECIMAL = (number) $10
|
||||
(const byte) RADIX::OCTAL = (number) 8
|
||||
(const word*) RADIX_DECIMAL_VALUES[] = { (word) $2710, (word) $3e8, (word) $64, (word) $a }
|
||||
(const dword*) RADIX_DECIMAL_VALUES_LONG[] = { (dword) $3b9aca00, (dword) $5f5e100, (dword) $989680, (dword) $f4240, (dword) $186a0, (dword) $2710, (dword) $3e8, (dword) $64, (dword) $a }
|
||||
(const byte) SIZEOF_STRUCT_PRINTF_BUFFER_NUMBER = (byte) $c
|
||||
(const nomodify byte) WHITE = (byte) 1
|
||||
(void()) clrscr()
|
||||
(label) clrscr::@1
|
||||
(label) clrscr::@2
|
||||
(label) clrscr::@3
|
||||
(label) clrscr::@4
|
||||
(label) clrscr::@5
|
||||
(label) clrscr::@return
|
||||
(byte) clrscr::c
|
||||
(byte) clrscr::c#1 reg byte y 20002.0
|
||||
(byte) clrscr::c#2 reg byte y 12501.25
|
||||
(byte) clrscr::l
|
||||
(byte) clrscr::l#1 reg byte x 2002.0
|
||||
(byte) clrscr::l#2 reg byte x 333.6666666666667
|
||||
(byte*) clrscr::line_cols
|
||||
(byte*) clrscr::line_cols#1 line_cols zp[2]:24 1001.0
|
||||
(byte*) clrscr::line_cols#5 line_cols zp[2]:24 1500.375
|
||||
(byte*) clrscr::line_text
|
||||
(byte*) clrscr::line_text#1 line_text zp[2]:20 667.3333333333334
|
||||
(byte*) clrscr::line_text#5 line_text zp[2]:20 1714.7142857142858
|
||||
(byte*) conio_cursor_color loadstore zp[2]:26 2.027272828272727E8
|
||||
(byte*) conio_cursor_text loadstore zp[2]:24 1.9734514257522124E8
|
||||
(byte) conio_cursor_x loadstore zp[1]:22 3.1481491768518522E7
|
||||
(byte) conio_cursor_y loadstore zp[1]:23 2.5967742831451613E8
|
||||
(byte) conio_textcolor loadstore zp[1]:28 6.87075517414966E7
|
||||
(void()) cputc((byte) cputc::c)
|
||||
(label) cputc::@1
|
||||
(label) cputc::@2
|
||||
(label) cputc::@3
|
||||
(label) cputc::@return
|
||||
(byte) cputc::c
|
||||
(byte) cputc::c#0 reg byte a 2.0000002E7
|
||||
(byte) cputc::c#1 reg byte a 2.0000002E7
|
||||
(byte) cputc::c#2 reg byte a 20002.0
|
||||
(byte) cputc::c#3 reg byte a 1.100050025E8
|
||||
(void()) cputln()
|
||||
(byte*~) cputln::$0 zp[2]:24 2.000000002E9
|
||||
(byte*~) cputln::$1 zp[2]:24 2.000000002E9
|
||||
(byte*~) cputln::$2 zp[2]:26 2.000000002E9
|
||||
(byte*~) cputln::$3 zp[2]:26 2.000000002E9
|
||||
(label) cputln::@return
|
||||
(void()) cputs((to_nomodify byte*) cputs::s)
|
||||
(label) cputs::@1
|
||||
(label) cputs::@2
|
||||
(label) cputs::@return
|
||||
(byte) cputs::c
|
||||
(byte) cputs::c#1 reg byte a 1.0000001E7
|
||||
(to_nomodify byte*) cputs::s
|
||||
(to_nomodify byte*) cputs::s#0 s zp[2]:35 5000000.5
|
||||
(to_nomodify byte*) cputs::s#4 s zp[2]:35 1.5050002E7
|
||||
(to_nomodify byte*) cputs::s#5 s zp[2]:35 100001.0
|
||||
(void()) cscroll()
|
||||
(byte*~) cscroll::$7 zp[2]:24 2.0000000002E10
|
||||
(byte*~) cscroll::$8 zp[2]:26 2.0000000002E10
|
||||
(label) cscroll::@1
|
||||
(label) cscroll::@2
|
||||
(label) cscroll::@3
|
||||
(label) cscroll::@4
|
||||
(label) cscroll::@5
|
||||
(label) cscroll::@return
|
||||
(void()) gotoxy((byte) gotoxy::x , (byte) gotoxy::y)
|
||||
(word~) gotoxy::$10 zp[2]:26 2002.0
|
||||
(word~) gotoxy::$4 zp[2]:26 2002.0
|
||||
(byte*~) gotoxy::$6 zp[2]:24 2002.0
|
||||
(byte*~) gotoxy::$7 zp[2]:26 2002.0
|
||||
(word~) gotoxy::$8 zp[2]:26 1501.5
|
||||
(word~) gotoxy::$9 zp[2]:35 2002.0
|
||||
(label) gotoxy::@1
|
||||
(label) gotoxy::@2
|
||||
(label) gotoxy::@3
|
||||
(label) gotoxy::@4
|
||||
(label) gotoxy::@return
|
||||
(word) gotoxy::offset
|
||||
(word) gotoxy::offset#0 offset zp[2]:26 1001.0
|
||||
(byte) gotoxy::x
|
||||
(byte) gotoxy::x#2 reg byte x 101.0
|
||||
(byte) gotoxy::x#4 reg byte x 350.5
|
||||
(byte) gotoxy::x#5 reg byte x 429.0
|
||||
(byte) gotoxy::y
|
||||
(byte) gotoxy::y#2 reg byte a 202.0
|
||||
(byte) gotoxy::y#4 reg byte a 701.0
|
||||
(byte) gotoxy::y#5 reg byte a 333.6666666666667
|
||||
(void()) main()
|
||||
(byte~) main::$17 reg byte a 202.0
|
||||
(label) main::@1
|
||||
(label) main::@10
|
||||
(label) main::@11
|
||||
(label) main::@12
|
||||
(label) main::@13
|
||||
(label) main::@14
|
||||
(label) main::@15
|
||||
(label) main::@16
|
||||
(label) main::@2
|
||||
(label) main::@3
|
||||
(label) main::@4
|
||||
(label) main::@5
|
||||
(label) main::@6
|
||||
(label) main::@7
|
||||
(label) main::@8
|
||||
(label) main::@9
|
||||
(label) main::@return
|
||||
(dword) main::cnt
|
||||
(dword) main::cnt#1 cnt zp[4]:2 9.681818181818182
|
||||
(dword) main::cnt#2 cnt zp[4]:2 202.0
|
||||
(byte) main::col
|
||||
(byte) main::col#1 col zp[1]:6 101.0
|
||||
(byte) main::col#3 col zp[1]:6 45.90909090909091
|
||||
(byte) main::col#7 col zp[1]:6 80.8
|
||||
(word) main::first
|
||||
(word) main::first#0 first zp[2]:29 5.590909090909091
|
||||
(word) main::rnd
|
||||
(word) main::rnd#1 rnd zp[2]:8 151.5
|
||||
(word) main::rnd#2 rnd zp[2]:8 30.42857142857143
|
||||
(word) main::rnd#5 rnd zp[2]:8 22.0
|
||||
(byte) main::row
|
||||
(byte) main::row#1 row zp[1]:7 151.5
|
||||
(byte) main::row#3 row zp[1]:7 44.888888888888886
|
||||
(byte) main::row#7 row zp[1]:7 60.599999999999994
|
||||
(const byte*) main::s[(byte) $1d] = (byte*) "generating unique randoms..."
|
||||
(const byte*) main::s1[(byte) 7] = (byte*) "found "
|
||||
(void*()) memcpy((void*) memcpy::destination , (void*) memcpy::source , (word) memcpy::num)
|
||||
(label) memcpy::@1
|
||||
(label) memcpy::@2
|
||||
(label) memcpy::@return
|
||||
(void*) memcpy::destination
|
||||
(void*) memcpy::destination#2 destination zp[2]:20
|
||||
(byte*) memcpy::dst
|
||||
(byte*) memcpy::dst#1 dst zp[2]:20 1.00000000000001E14
|
||||
(byte*) memcpy::dst#2 dst zp[2]:20 1.0003333333333467E14
|
||||
(byte*) memcpy::dst#4 dst zp[2]:20 2.00000000002E11
|
||||
(word) memcpy::num
|
||||
(void*) memcpy::return
|
||||
(void*) memcpy::source
|
||||
(void*) memcpy::source#2 source zp[2]:39
|
||||
(byte*) memcpy::src
|
||||
(byte*) memcpy::src#1 src zp[2]:39 2.00000000000002E14
|
||||
(byte*) memcpy::src#2 src zp[2]:39 1.0002500000000125E14
|
||||
(byte*) memcpy::src#4 src zp[2]:39 1.00000000001E11
|
||||
(byte*) memcpy::src_end
|
||||
(byte*) memcpy::src_end#0 src_end zp[2]:37 1.251250000000025E13
|
||||
(void*()) memset((void*) memset::str , (byte) memset::c , (word) memset::num)
|
||||
(label) memset::@1
|
||||
(label) memset::@2
|
||||
(label) memset::@3
|
||||
(label) memset::@return
|
||||
(byte) memset::c
|
||||
(byte) memset::c#1 reg byte x 2.0000000002E10
|
||||
(byte) memset::c#4 reg byte x 1.4287142857143143E13
|
||||
(byte*) memset::dst
|
||||
(byte*) memset::dst#1 dst zp[2]:39 2.00000000000002E14
|
||||
(byte*) memset::dst#2 dst zp[2]:39 1.3336666666666834E14
|
||||
(byte*) memset::dst#4 dst zp[2]:39 2.00000000002E11
|
||||
(byte*) memset::end
|
||||
(byte*) memset::end#0 end zp[2]:37 1.6683333333333668E13
|
||||
(word) memset::num
|
||||
(void*) memset::return
|
||||
(void*) memset::str
|
||||
(void*) memset::str#3 str zp[2]:39
|
||||
(struct printf_buffer_number) printf_buffer loadstore mem[12] = {}
|
||||
(const byte*) printf_buffer_number::digits[(number) $b] = { fill( $b, 0) }
|
||||
(byte) printf_buffer_number::sign
|
||||
(byte) printf_format_number::justify_left
|
||||
(byte) printf_format_number::min_length
|
||||
(byte) printf_format_number::radix
|
||||
(byte) printf_format_number::sign_always
|
||||
(byte) printf_format_number::upper_case
|
||||
(byte) printf_format_number::zero_padding
|
||||
(byte) printf_format_string::justify_left
|
||||
(byte) printf_format_string::min_length
|
||||
(void()) printf_number_buffer((byte) printf_number_buffer::buffer_sign , (byte*) printf_number_buffer::buffer_digits , (byte) printf_number_buffer::format_min_length , (byte) printf_number_buffer::format_justify_left , (byte) printf_number_buffer::format_sign_always , (byte) printf_number_buffer::format_zero_padding , (byte) printf_number_buffer::format_upper_case , (byte) printf_number_buffer::format_radix)
|
||||
(word~) printf_number_buffer::$19 zp[2]:39 10001.0
|
||||
(label) printf_number_buffer::@1
|
||||
(label) printf_number_buffer::@10
|
||||
(label) printf_number_buffer::@11
|
||||
(label) printf_number_buffer::@12
|
||||
(label) printf_number_buffer::@13
|
||||
(label) printf_number_buffer::@14
|
||||
(label) printf_number_buffer::@15
|
||||
(label) printf_number_buffer::@16
|
||||
(label) printf_number_buffer::@17
|
||||
(label) printf_number_buffer::@18
|
||||
(label) printf_number_buffer::@19
|
||||
(label) printf_number_buffer::@2
|
||||
(label) printf_number_buffer::@20
|
||||
(label) printf_number_buffer::@21
|
||||
(label) printf_number_buffer::@3
|
||||
(label) printf_number_buffer::@4
|
||||
(label) printf_number_buffer::@5
|
||||
(label) printf_number_buffer::@6
|
||||
(label) printf_number_buffer::@7
|
||||
(label) printf_number_buffer::@8
|
||||
(label) printf_number_buffer::@9
|
||||
(label) printf_number_buffer::@return
|
||||
(struct printf_buffer_number) printf_number_buffer::buffer
|
||||
(byte*) printf_number_buffer::buffer_digits
|
||||
(byte) printf_number_buffer::buffer_sign
|
||||
(byte) printf_number_buffer::buffer_sign#0 buffer_sign zp[1]:10 202.0
|
||||
(byte) printf_number_buffer::buffer_sign#1 buffer_sign zp[1]:10 2002.0
|
||||
(byte) printf_number_buffer::buffer_sign#10 buffer_sign zp[1]:10 1555.25
|
||||
(struct printf_format_number) printf_number_buffer::format
|
||||
(byte) printf_number_buffer::format_justify_left
|
||||
(byte) printf_number_buffer::format_justify_left#10 format_justify_left zp[1]:16 645.2258064516129
|
||||
(byte) printf_number_buffer::format_min_length
|
||||
(byte) printf_number_buffer::format_min_length#2 reg byte x 1000.1
|
||||
(byte) printf_number_buffer::format_radix
|
||||
(byte) printf_number_buffer::format_sign_always
|
||||
(byte) printf_number_buffer::format_upper_case
|
||||
(byte) printf_number_buffer::format_upper_case#10 format_upper_case zp[1]:11 384.65384615384613
|
||||
(byte) printf_number_buffer::format_zero_padding
|
||||
(byte) printf_number_buffer::format_zero_padding#10 format_zero_padding zp[1]:19 937.59375
|
||||
(signed byte) printf_number_buffer::len
|
||||
(signed byte) printf_number_buffer::len#0 reg byte y 15001.5
|
||||
(signed byte) printf_number_buffer::len#1 reg byte y 20002.0
|
||||
(signed byte) printf_number_buffer::len#2 reg byte y 30003.0
|
||||
(signed byte) printf_number_buffer::padding
|
||||
(signed byte) printf_number_buffer::padding#1 padding zp[1]:12 10001.0
|
||||
(signed byte) printf_number_buffer::padding#10 padding zp[1]:12 1904.952380952381
|
||||
(void()) printf_padding((byte) printf_padding::pad , (byte) printf_padding::length)
|
||||
(label) printf_padding::@1
|
||||
(label) printf_padding::@2
|
||||
(label) printf_padding::@3
|
||||
(label) printf_padding::@return
|
||||
(byte) printf_padding::i
|
||||
(byte) printf_padding::i#1 i zp[1]:15 2.0000002E7
|
||||
(byte) printf_padding::i#2 i zp[1]:15 7500000.75
|
||||
(byte) printf_padding::length
|
||||
(byte) printf_padding::length#0 length zp[1]:13 20002.0
|
||||
(byte) printf_padding::length#1 length zp[1]:13 20002.0
|
||||
(byte) printf_padding::length#2 length zp[1]:13 20002.0
|
||||
(byte) printf_padding::length#4 length zp[1]:13 1671667.3333333333
|
||||
(byte) printf_padding::pad
|
||||
(byte) printf_padding::pad#5 pad zp[1]:14 1666666.8333333333
|
||||
(void()) printf_uint((word) printf_uint::uvalue , (byte) printf_uint::format_min_length , (byte) printf_uint::format_justify_left , (byte) printf_uint::format_sign_always , (byte) printf_uint::format_zero_padding , (byte) printf_uint::format_upper_case , (byte) printf_uint::format_radix)
|
||||
(label) printf_uint::@1
|
||||
(label) printf_uint::@2
|
||||
(label) printf_uint::@return
|
||||
(struct printf_format_number) printf_uint::format
|
||||
(byte) printf_uint::format_justify_left
|
||||
(const byte) printf_uint::format_justify_left#0 format_justify_left = (byte) 0
|
||||
(byte) printf_uint::format_min_length
|
||||
(const byte) printf_uint::format_min_length#0 format_min_length = (byte) 5
|
||||
(byte) printf_uint::format_radix
|
||||
(byte) printf_uint::format_sign_always
|
||||
(byte) printf_uint::format_upper_case
|
||||
(const byte) printf_uint::format_upper_case#0 format_upper_case = (byte) 0
|
||||
(byte) printf_uint::format_zero_padding
|
||||
(const byte) printf_uint::format_zero_padding#0 format_zero_padding = (byte) 0
|
||||
(word) printf_uint::uvalue
|
||||
(word) printf_uint::uvalue#0 uvalue zp[2]:8 367.33333333333337
|
||||
(void()) printf_ulong((dword) printf_ulong::uvalue , (byte) printf_ulong::format_min_length , (byte) printf_ulong::format_justify_left , (byte) printf_ulong::format_sign_always , (byte) printf_ulong::format_zero_padding , (byte) printf_ulong::format_upper_case , (byte) printf_ulong::format_radix)
|
||||
(label) printf_ulong::@1
|
||||
(label) printf_ulong::@2
|
||||
(label) printf_ulong::@return
|
||||
(struct printf_format_number) printf_ulong::format
|
||||
(byte) printf_ulong::format_justify_left
|
||||
(const byte) printf_ulong::format_justify_left#0 format_justify_left = (byte) 0
|
||||
(byte) printf_ulong::format_min_length
|
||||
(const byte) printf_ulong::format_min_length#0 format_min_length = (byte) 0
|
||||
(byte) printf_ulong::format_radix
|
||||
(byte) printf_ulong::format_sign_always
|
||||
(byte) printf_ulong::format_upper_case
|
||||
(const byte) printf_ulong::format_upper_case#0 format_upper_case = (byte) 0
|
||||
(byte) printf_ulong::format_zero_padding
|
||||
(const byte) printf_ulong::format_zero_padding#0 format_zero_padding = (byte) 0
|
||||
(dword) printf_ulong::uvalue
|
||||
(dword) printf_ulong::uvalue#0 uvalue zp[4]:2 37.33333333333333
|
||||
(word()) rand()
|
||||
(word~) rand::$0 zp[2]:35 2002.0
|
||||
(word~) rand::$1 zp[2]:39 2002.0
|
||||
(word~) rand::$2 zp[2]:37 2002.0
|
||||
(label) rand::@return
|
||||
(word) rand::return
|
||||
(word) rand::return#0 return zp[2]:29 22.0
|
||||
(word) rand::return#1 return_1 zp[2]:8 202.0
|
||||
(word) rand::return#2 return_1 zp[2]:8 278.25
|
||||
(word) rand_state
|
||||
(word) rand_state#12 rand_state zp[2]:17 1051.5
|
||||
(word) rand_state#13 rand_state zp[2]:17 77.88888888888889
|
||||
(word) rand_state#4 rand_state zp[2]:17 1501.5
|
||||
(word) rand_state#5 rand_state zp[2]:17 1501.5
|
||||
(word()) strlen((byte*) strlen::str)
|
||||
(label) strlen::@1
|
||||
(label) strlen::@2
|
||||
(label) strlen::@return
|
||||
(word) strlen::len
|
||||
(word) strlen::len#1 len zp[2]:39 1.0000001E7
|
||||
(word) strlen::len#2 len zp[2]:39 5002500.75
|
||||
(word) strlen::return
|
||||
(word) strlen::return#2 return zp[2]:39 20002.0
|
||||
(byte*) strlen::str
|
||||
(byte*) strlen::str#0 str zp[2]:35 2.0000002E7
|
||||
(byte*) strlen::str#2 str zp[2]:35 1.0000001E7
|
||||
(byte*()) strupr((byte*) strupr::str)
|
||||
(byte~) strupr::$0 reg byte a 2.0000002E7
|
||||
(label) strupr::@1
|
||||
(label) strupr::@2
|
||||
(label) strupr::@3
|
||||
(label) strupr::@return
|
||||
(byte*) strupr::return
|
||||
(byte*) strupr::src
|
||||
(byte*) strupr::src#1 src zp[2]:20 2.0000002E7
|
||||
(byte*) strupr::src#2 src zp[2]:20 7142857.857142856
|
||||
(byte*) strupr::str
|
||||
(const byte*) strupr::str#0 str = (byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
(byte()) textcolor((byte) textcolor::color)
|
||||
(label) textcolor::@return
|
||||
(byte) textcolor::color
|
||||
(byte) textcolor::color#2 reg byte a 101.0
|
||||
(byte) textcolor::old
|
||||
(byte) textcolor::return
|
||||
(byte()) toupper((byte) toupper::ch)
|
||||
(label) toupper::@1
|
||||
(label) toupper::@2
|
||||
(label) toupper::@return
|
||||
(byte) toupper::ch
|
||||
(byte) toupper::ch#0 reg byte a 1.70000002E8
|
||||
(byte) toupper::return
|
||||
(byte) toupper::return#0 reg byte a 2.00000002E8
|
||||
(byte) toupper::return#2 reg byte a 1.0333333466666667E8
|
||||
(byte) toupper::return#3 reg byte a 2.0000002E7
|
||||
(void()) ultoa((dword) ultoa::value , (byte*) ultoa::buffer , (byte) ultoa::radix)
|
||||
(byte~) ultoa::$10 reg byte a 20002.0
|
||||
(byte~) ultoa::$11 reg byte a 2002.0
|
||||
(label) ultoa::@1
|
||||
(label) ultoa::@2
|
||||
(label) ultoa::@3
|
||||
(label) ultoa::@4
|
||||
(label) ultoa::@5
|
||||
(label) ultoa::@6
|
||||
(label) ultoa::@7
|
||||
(label) ultoa::@return
|
||||
(byte*) ultoa::buffer
|
||||
(byte*) ultoa::buffer#11 buffer zp[2]:39 3000.4285714285716
|
||||
(byte*) ultoa::buffer#14 buffer zp[2]:39 15001.5
|
||||
(byte*) ultoa::buffer#3 buffer zp[2]:39 2002.0
|
||||
(byte*) ultoa::buffer#4 buffer zp[2]:39 20002.0
|
||||
(byte) ultoa::digit
|
||||
(byte) ultoa::digit#1 digit zp[1]:16 20002.0
|
||||
(byte) ultoa::digit#2 digit zp[1]:16 2857.4285714285716
|
||||
(dword) ultoa::digit_value
|
||||
(dword) ultoa::digit_value#0 digit_value zp[4]:31 6000.6
|
||||
(dword*) ultoa::digit_values
|
||||
(byte) ultoa::max_digits
|
||||
(const byte) ultoa::max_digits#1 max_digits = (byte) $a
|
||||
(byte) ultoa::radix
|
||||
(byte) ultoa::started
|
||||
(byte) ultoa::started#2 reg byte x 5000.5
|
||||
(byte) ultoa::started#4 reg byte x 10001.0
|
||||
(dword) ultoa::value
|
||||
(dword) ultoa::value#0 value zp[4]:2 10001.0
|
||||
(dword) ultoa::value#1 value zp[4]:2 551.0
|
||||
(dword) ultoa::value#2 value zp[4]:2 5857.857142857143
|
||||
(dword) ultoa::value#6 value zp[4]:2 15001.5
|
||||
(dword()) ultoa_append((byte*) ultoa_append::buffer , (dword) ultoa_append::value , (dword) ultoa_append::sub)
|
||||
(label) ultoa_append::@1
|
||||
(label) ultoa_append::@2
|
||||
(label) ultoa_append::@3
|
||||
(label) ultoa_append::@return
|
||||
(byte*) ultoa_append::buffer
|
||||
(byte*) ultoa_append::buffer#0 buffer zp[2]:39 13750.25
|
||||
(byte) ultoa_append::digit
|
||||
(byte) ultoa_append::digit#1 reg byte x 1.0000001E7
|
||||
(byte) ultoa_append::digit#2 reg byte x 1.00500015E7
|
||||
(dword) ultoa_append::return
|
||||
(dword) ultoa_append::return#0 return zp[4]:2 20002.0
|
||||
(dword) ultoa_append::sub
|
||||
(dword) ultoa_append::sub#0 sub zp[4]:31 3335000.5
|
||||
(dword) ultoa_append::value
|
||||
(dword) ultoa_append::value#0 value zp[4]:2 36667.33333333333
|
||||
(dword) ultoa_append::value#1 value zp[4]:2 2.0000002E7
|
||||
(dword) ultoa_append::value#2 value zp[4]:2 5018334.166666666
|
||||
(void()) utoa((word) utoa::value , (byte*) utoa::buffer , (byte) utoa::radix)
|
||||
(byte~) utoa::$10 reg byte a 2000002.0
|
||||
(byte~) utoa::$11 reg byte a 20002.0
|
||||
(label) utoa::@1
|
||||
(label) utoa::@2
|
||||
(label) utoa::@3
|
||||
(label) utoa::@4
|
||||
(label) utoa::@5
|
||||
(label) utoa::@6
|
||||
(label) utoa::@7
|
||||
(label) utoa::@return
|
||||
(byte*) utoa::buffer
|
||||
(byte*) utoa::buffer#11 buffer zp[2]:20 287143.2857142857
|
||||
(byte*) utoa::buffer#14 buffer zp[2]:20 1500001.5
|
||||
(byte*) utoa::buffer#3 buffer zp[2]:20 20002.0
|
||||
(byte*) utoa::buffer#4 buffer zp[2]:20 2000002.0
|
||||
(byte) utoa::digit
|
||||
(byte) utoa::digit#1 digit zp[1]:19 2000002.0
|
||||
(byte) utoa::digit#2 digit zp[1]:19 285714.5714285714
|
||||
(word) utoa::digit_value
|
||||
(word) utoa::digit_value#0 digit_value zp[2]:39 600000.6000000001
|
||||
(word*) utoa::digit_values
|
||||
(byte) utoa::max_digits
|
||||
(const byte) utoa::max_digits#1 max_digits = (byte) 5
|
||||
(byte) utoa::radix
|
||||
(byte) utoa::started
|
||||
(byte) utoa::started#2 reg byte x 500000.5
|
||||
(byte) utoa::started#4 reg byte x 1000001.0
|
||||
(word) utoa::value
|
||||
(word) utoa::value#0 value zp[2]:8 1000001.0
|
||||
(word) utoa::value#1 value zp[2]:8 5501.0
|
||||
(word) utoa::value#2 value zp[2]:8 572857.857142857
|
||||
(word) utoa::value#6 value zp[2]:8 1500001.5
|
||||
(word()) utoa_append((byte*) utoa_append::buffer , (word) utoa_append::value , (word) utoa_append::sub)
|
||||
(label) utoa_append::@1
|
||||
(label) utoa_append::@2
|
||||
(label) utoa_append::@3
|
||||
(label) utoa_append::@return
|
||||
(byte*) utoa_append::buffer
|
||||
(byte*) utoa_append::buffer#0 buffer zp[2]:20 1375000.25
|
||||
(byte) utoa_append::digit
|
||||
(byte) utoa_append::digit#1 reg byte x 1.0000000001E10
|
||||
(byte) utoa_append::digit#2 reg byte x 1.00050000015E10
|
||||
(word) utoa_append::return
|
||||
(word) utoa_append::return#0 return zp[2]:8 2000002.0
|
||||
(word) utoa_append::sub
|
||||
(word) utoa_append::sub#0 sub zp[2]:39 3.3335000005E9
|
||||
(word) utoa_append::value
|
||||
(word) utoa_append::value#0 value zp[2]:8 3666667.333333333
|
||||
(word) utoa_append::value#1 value zp[2]:8 2.0000000002E10
|
||||
(word) utoa_append::value#2 value zp[2]:8 5.001833334166666E9
|
||||
|
||||
zp[4]:2 [ main::cnt#2 main::cnt#1 printf_ulong::uvalue#0 ultoa::value#2 ultoa::value#6 ultoa::value#1 ultoa::value#0 ultoa_append::value#2 ultoa_append::value#0 ultoa_append::value#1 ultoa_append::return#0 ]
|
||||
zp[1]:6 [ main::col#3 main::col#7 main::col#1 ]
|
||||
zp[1]:7 [ main::row#3 main::row#7 main::row#1 ]
|
||||
zp[2]:8 [ main::rnd#2 main::rnd#5 main::rnd#1 printf_uint::uvalue#0 rand::return#1 utoa::value#2 utoa::value#6 utoa::value#1 utoa::value#0 utoa_append::value#2 utoa_append::value#0 utoa_append::value#1 utoa_append::return#0 rand::return#2 ]
|
||||
reg byte x [ printf_number_buffer::format_min_length#2 ]
|
||||
zp[1]:10 [ printf_number_buffer::buffer_sign#10 printf_number_buffer::buffer_sign#1 printf_number_buffer::buffer_sign#0 ]
|
||||
zp[1]:11 [ printf_number_buffer::format_upper_case#10 ]
|
||||
reg byte y [ printf_number_buffer::len#2 printf_number_buffer::len#0 printf_number_buffer::len#1 ]
|
||||
zp[1]:12 [ printf_number_buffer::padding#10 printf_number_buffer::padding#1 ]
|
||||
zp[1]:13 [ printf_padding::length#4 printf_padding::length#1 printf_padding::length#2 printf_padding::length#0 ]
|
||||
zp[1]:14 [ printf_padding::pad#5 ]
|
||||
zp[1]:15 [ printf_padding::i#2 printf_padding::i#1 ]
|
||||
reg byte a [ cputc::c#3 cputc::c#0 cputc::c#2 cputc::c#1 ]
|
||||
reg byte x [ memset::c#4 memset::c#1 ]
|
||||
reg byte a [ toupper::return#2 toupper::return#0 toupper::ch#0 ]
|
||||
zp[1]:16 [ ultoa::digit#2 ultoa::digit#1 printf_number_buffer::format_justify_left#10 ]
|
||||
reg byte x [ ultoa::started#2 ultoa::started#4 ]
|
||||
reg byte x [ ultoa_append::digit#2 ultoa_append::digit#1 ]
|
||||
reg byte a [ gotoxy::y#5 gotoxy::y#4 gotoxy::y#2 ]
|
||||
reg byte x [ gotoxy::x#5 gotoxy::x#4 gotoxy::x#2 ]
|
||||
zp[2]:17 [ rand_state#12 rand_state#13 rand_state#4 rand_state#5 ]
|
||||
zp[1]:19 [ utoa::digit#2 utoa::digit#1 printf_number_buffer::format_zero_padding#10 ]
|
||||
reg byte x [ utoa::started#2 utoa::started#4 ]
|
||||
reg byte x [ utoa_append::digit#2 utoa_append::digit#1 ]
|
||||
reg byte a [ textcolor::color#2 ]
|
||||
reg byte x [ clrscr::l#2 clrscr::l#1 ]
|
||||
zp[2]:20 [ clrscr::line_text#5 clrscr::line_text#1 utoa::buffer#11 utoa::buffer#14 utoa::buffer#4 utoa::buffer#3 utoa_append::buffer#0 strupr::src#2 strupr::src#1 memcpy::destination#2 memcpy::dst#2 memcpy::dst#4 memcpy::dst#1 ]
|
||||
reg byte y [ clrscr::c#2 clrscr::c#1 ]
|
||||
zp[1]:22 [ conio_cursor_x ]
|
||||
zp[1]:23 [ conio_cursor_y ]
|
||||
zp[2]:24 [ conio_cursor_text cscroll::$7 cputln::$0 cputln::$1 gotoxy::$6 clrscr::line_cols#5 clrscr::line_cols#1 ]
|
||||
zp[2]:26 [ conio_cursor_color cscroll::$8 cputln::$2 cputln::$3 gotoxy::$7 gotoxy::$4 gotoxy::offset#0 gotoxy::$8 gotoxy::$10 ]
|
||||
zp[1]:28 [ conio_textcolor ]
|
||||
zp[2]:29 [ rand::return#0 main::first#0 ]
|
||||
reg byte a [ main::$17 ]
|
||||
reg byte a [ cputs::c#1 ]
|
||||
reg byte a [ toupper::return#3 ]
|
||||
reg byte a [ strupr::$0 ]
|
||||
reg byte a [ ultoa::$11 ]
|
||||
reg byte a [ ultoa::$10 ]
|
||||
zp[4]:31 [ ultoa::digit_value#0 ultoa_append::sub#0 ]
|
||||
zp[2]:35 [ rand::$0 gotoxy::$9 strlen::str#2 strlen::str#0 cputs::s#4 cputs::s#5 cputs::s#0 ]
|
||||
zp[2]:37 [ rand::$2 memcpy::src_end#0 memset::end#0 ]
|
||||
reg byte a [ utoa::$11 ]
|
||||
reg byte a [ utoa::$10 ]
|
||||
zp[2]:39 [ utoa::digit_value#0 utoa_append::sub#0 rand::$1 ultoa::buffer#11 ultoa::buffer#14 ultoa::buffer#4 ultoa::buffer#3 ultoa_append::buffer#0 strlen::len#2 strlen::len#1 strlen::return#2 printf_number_buffer::$19 memcpy::source#2 memcpy::src#2 memcpy::src#4 memcpy::src#1 memset::str#3 memset::dst#2 memset::dst#4 memset::dst#1 ]
|
||||
mem[12] [ printf_buffer ]
|
944
src/test/ref/stars-1.asm
Normal file
944
src/test/ref/stars-1.asm
Normal file
@ -0,0 +1,944 @@
|
||||
// Stars array of struct
|
||||
.pc = $801 "Basic"
|
||||
:BasicUpstart(__bbegin)
|
||||
.pc = $80d "Program"
|
||||
// The default text color
|
||||
.const CONIO_TEXTCOLOR_DEFAULT = $e
|
||||
.const OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS = 1
|
||||
.const SIZEOF_STRUCT_PRINTF_BUFFER_NUMBER = $c
|
||||
// The screen width
|
||||
// The screen height
|
||||
// The screen bytes
|
||||
// The text screen address
|
||||
.label CONIO_SCREEN_TEXT = $400
|
||||
// The color screen address
|
||||
.label CONIO_SCREEN_COLORS = $d800
|
||||
.label conio_cursor_x = $12
|
||||
.label conio_cursor_y = $13
|
||||
.label conio_cursor_text = $14
|
||||
.label conio_cursor_color = $16
|
||||
__bbegin:
|
||||
// conio_cursor_x = 0
|
||||
// The current cursor x-position
|
||||
lda #0
|
||||
sta.z conio_cursor_x
|
||||
// conio_cursor_y = 0
|
||||
// The current cursor y-position
|
||||
sta.z conio_cursor_y
|
||||
// conio_cursor_text = CONIO_SCREEN_TEXT
|
||||
// The current cursor address
|
||||
lda #<CONIO_SCREEN_TEXT
|
||||
sta.z conio_cursor_text
|
||||
lda #>CONIO_SCREEN_TEXT
|
||||
sta.z conio_cursor_text+1
|
||||
// conio_cursor_color = CONIO_SCREEN_COLORS
|
||||
// The current cursor address
|
||||
lda #<CONIO_SCREEN_COLORS
|
||||
sta.z conio_cursor_color
|
||||
lda #>CONIO_SCREEN_COLORS
|
||||
sta.z conio_cursor_color+1
|
||||
jsr main
|
||||
rts
|
||||
main: {
|
||||
.label pStar = 3
|
||||
.label i = 2
|
||||
// clrscr()
|
||||
jsr clrscr
|
||||
lda #<stars
|
||||
sta.z pStar
|
||||
lda #>stars
|
||||
sta.z pStar+1
|
||||
lda #0
|
||||
sta.z i
|
||||
__b1:
|
||||
// for( char i=0;i<5;i++)
|
||||
lda.z i
|
||||
cmp #5
|
||||
bcc __b2
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// printf("%p %u %u\n", pStar, pStar->star_x, pStar->star_y)
|
||||
lda.z pStar
|
||||
sta.z printf_uint.uvalue
|
||||
lda.z pStar+1
|
||||
sta.z printf_uint.uvalue+1
|
||||
jsr printf_uint
|
||||
// printf("%p %u %u\n", pStar, pStar->star_x, pStar->star_y)
|
||||
lda #<s
|
||||
sta.z cputs.s
|
||||
lda #>s
|
||||
sta.z cputs.s+1
|
||||
jsr cputs
|
||||
// printf("%p %u %u\n", pStar, pStar->star_x, pStar->star_y)
|
||||
ldy #0
|
||||
lda (pStar),y
|
||||
tax
|
||||
jsr printf_uchar
|
||||
// printf("%p %u %u\n", pStar, pStar->star_x, pStar->star_y)
|
||||
lda #<s
|
||||
sta.z cputs.s
|
||||
lda #>s
|
||||
sta.z cputs.s+1
|
||||
jsr cputs
|
||||
// printf("%p %u %u\n", pStar, pStar->star_x, pStar->star_y)
|
||||
ldy #1
|
||||
lda (pStar),y
|
||||
tax
|
||||
jsr printf_uchar
|
||||
// printf("%p %u %u\n", pStar, pStar->star_x, pStar->star_y)
|
||||
lda #<s2
|
||||
sta.z cputs.s
|
||||
lda #>s2
|
||||
sta.z cputs.s+1
|
||||
jsr cputs
|
||||
// pStar++;
|
||||
lda #4
|
||||
clc
|
||||
adc.z pStar
|
||||
sta.z pStar
|
||||
bcc !+
|
||||
inc.z pStar+1
|
||||
!:
|
||||
// for( char i=0;i<5;i++)
|
||||
inc.z i
|
||||
jmp __b1
|
||||
s: .text " "
|
||||
.byte 0
|
||||
s2: .text @"\n"
|
||||
.byte 0
|
||||
}
|
||||
// Output a NUL-terminated string at the current cursor position
|
||||
// cputs(byte* zp($e) s)
|
||||
cputs: {
|
||||
.label s = $e
|
||||
__b1:
|
||||
// c=*s++
|
||||
ldy #0
|
||||
lda (s),y
|
||||
// while(c=*s++)
|
||||
inc.z s
|
||||
bne !+
|
||||
inc.z s+1
|
||||
!:
|
||||
cmp #0
|
||||
bne __b2
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// cputc(c)
|
||||
jsr cputc
|
||||
jmp __b1
|
||||
}
|
||||
// Output one character at the current cursor position
|
||||
// Moves the cursor forward. Scrolls the entire screen if needed
|
||||
// cputc(byte register(A) c)
|
||||
cputc: {
|
||||
// if(c=='\n')
|
||||
cmp #'\n'
|
||||
beq __b1
|
||||
// *conio_cursor_text++ = c
|
||||
ldy #0
|
||||
sta (conio_cursor_text),y
|
||||
// *conio_cursor_text++ = c;
|
||||
inc.z conio_cursor_text
|
||||
bne !+
|
||||
inc.z conio_cursor_text+1
|
||||
!:
|
||||
// *conio_cursor_color++ = conio_textcolor
|
||||
lda #CONIO_TEXTCOLOR_DEFAULT
|
||||
ldy #0
|
||||
sta (conio_cursor_color),y
|
||||
// *conio_cursor_color++ = conio_textcolor;
|
||||
inc.z conio_cursor_color
|
||||
bne !+
|
||||
inc.z conio_cursor_color+1
|
||||
!:
|
||||
// if(++conio_cursor_x==CONIO_WIDTH)
|
||||
inc.z conio_cursor_x
|
||||
lda #$28
|
||||
cmp.z conio_cursor_x
|
||||
bne __breturn
|
||||
// conio_cursor_x = 0
|
||||
lda #0
|
||||
sta.z conio_cursor_x
|
||||
// ++conio_cursor_y;
|
||||
inc.z conio_cursor_y
|
||||
// cscroll()
|
||||
jsr cscroll
|
||||
__breturn:
|
||||
// }
|
||||
rts
|
||||
__b1:
|
||||
// cputln()
|
||||
jsr cputln
|
||||
rts
|
||||
}
|
||||
// Print a newline
|
||||
cputln: {
|
||||
.label __0 = $14
|
||||
.label __1 = $14
|
||||
.label __2 = $16
|
||||
.label __3 = $16
|
||||
// conio_cursor_text - conio_cursor_x
|
||||
sec
|
||||
lda.z __0
|
||||
sbc.z conio_cursor_x
|
||||
sta.z __0
|
||||
bcs !+
|
||||
dec.z __0+1
|
||||
!:
|
||||
// conio_cursor_text - conio_cursor_x + CONIO_WIDTH
|
||||
lda #$28
|
||||
clc
|
||||
adc.z __1
|
||||
sta.z __1
|
||||
bcc !+
|
||||
inc.z __1+1
|
||||
!:
|
||||
// conio_cursor_text = conio_cursor_text - conio_cursor_x + CONIO_WIDTH
|
||||
// conio_cursor_color - conio_cursor_x
|
||||
sec
|
||||
lda.z __2
|
||||
sbc.z conio_cursor_x
|
||||
sta.z __2
|
||||
bcs !+
|
||||
dec.z __2+1
|
||||
!:
|
||||
// conio_cursor_color - conio_cursor_x + CONIO_WIDTH
|
||||
lda #$28
|
||||
clc
|
||||
adc.z __3
|
||||
sta.z __3
|
||||
bcc !+
|
||||
inc.z __3+1
|
||||
!:
|
||||
// conio_cursor_color = conio_cursor_color - conio_cursor_x + CONIO_WIDTH
|
||||
// conio_cursor_x = 0
|
||||
lda #0
|
||||
sta.z conio_cursor_x
|
||||
// conio_cursor_y++;
|
||||
inc.z conio_cursor_y
|
||||
// cscroll()
|
||||
jsr cscroll
|
||||
// }
|
||||
rts
|
||||
}
|
||||
// Scroll the entire screen if the cursor is beyond the last line
|
||||
cscroll: {
|
||||
.label __7 = $14
|
||||
.label __8 = $16
|
||||
// if(conio_cursor_y==CONIO_HEIGHT)
|
||||
lda #$19
|
||||
cmp.z conio_cursor_y
|
||||
bne __breturn
|
||||
// memcpy(CONIO_SCREEN_TEXT, CONIO_SCREEN_TEXT+CONIO_WIDTH, CONIO_BYTES-CONIO_WIDTH)
|
||||
lda #<CONIO_SCREEN_TEXT
|
||||
sta.z memcpy.destination
|
||||
lda #>CONIO_SCREEN_TEXT
|
||||
sta.z memcpy.destination+1
|
||||
lda #<CONIO_SCREEN_TEXT+$28
|
||||
sta.z memcpy.source
|
||||
lda #>CONIO_SCREEN_TEXT+$28
|
||||
sta.z memcpy.source+1
|
||||
jsr memcpy
|
||||
// memcpy(CONIO_SCREEN_COLORS, CONIO_SCREEN_COLORS+CONIO_WIDTH, CONIO_BYTES-CONIO_WIDTH)
|
||||
lda #<CONIO_SCREEN_COLORS
|
||||
sta.z memcpy.destination
|
||||
lda #>CONIO_SCREEN_COLORS
|
||||
sta.z memcpy.destination+1
|
||||
lda #<CONIO_SCREEN_COLORS+$28
|
||||
sta.z memcpy.source
|
||||
lda #>CONIO_SCREEN_COLORS+$28
|
||||
sta.z memcpy.source+1
|
||||
jsr memcpy
|
||||
// memset(CONIO_SCREEN_TEXT+CONIO_BYTES-CONIO_WIDTH, ' ', CONIO_WIDTH)
|
||||
ldx #' '
|
||||
lda #<CONIO_SCREEN_TEXT+$19*$28-$28
|
||||
sta.z memset.str
|
||||
lda #>CONIO_SCREEN_TEXT+$19*$28-$28
|
||||
sta.z memset.str+1
|
||||
jsr memset
|
||||
// memset(CONIO_SCREEN_COLORS+CONIO_BYTES-CONIO_WIDTH, conio_textcolor, CONIO_WIDTH)
|
||||
ldx #CONIO_TEXTCOLOR_DEFAULT
|
||||
lda #<CONIO_SCREEN_COLORS+$19*$28-$28
|
||||
sta.z memset.str
|
||||
lda #>CONIO_SCREEN_COLORS+$19*$28-$28
|
||||
sta.z memset.str+1
|
||||
jsr memset
|
||||
// conio_cursor_text-CONIO_WIDTH
|
||||
lda.z __7
|
||||
sec
|
||||
sbc #<$28
|
||||
sta.z __7
|
||||
lda.z __7+1
|
||||
sbc #>$28
|
||||
sta.z __7+1
|
||||
// conio_cursor_text = conio_cursor_text-CONIO_WIDTH
|
||||
// conio_cursor_color-CONIO_WIDTH
|
||||
lda.z __8
|
||||
sec
|
||||
sbc #<$28
|
||||
sta.z __8
|
||||
lda.z __8+1
|
||||
sbc #>$28
|
||||
sta.z __8+1
|
||||
// conio_cursor_color = conio_cursor_color-CONIO_WIDTH
|
||||
// conio_cursor_y--;
|
||||
dec.z conio_cursor_y
|
||||
__breturn:
|
||||
// }
|
||||
rts
|
||||
}
|
||||
// Copies the character c (an unsigned char) to the first num characters of the object pointed to by the argument str.
|
||||
// memset(void* zp($b) str, byte register(X) c)
|
||||
memset: {
|
||||
.label end = $19
|
||||
.label dst = $b
|
||||
.label str = $b
|
||||
// end = (char*)str + num
|
||||
lda #$28
|
||||
clc
|
||||
adc.z str
|
||||
sta.z end
|
||||
lda #0
|
||||
adc.z str+1
|
||||
sta.z end+1
|
||||
__b2:
|
||||
// for(char* dst = str; dst!=end; dst++)
|
||||
lda.z dst+1
|
||||
cmp.z end+1
|
||||
bne __b3
|
||||
lda.z dst
|
||||
cmp.z end
|
||||
bne __b3
|
||||
// }
|
||||
rts
|
||||
__b3:
|
||||
// *dst = c
|
||||
txa
|
||||
ldy #0
|
||||
sta (dst),y
|
||||
// for(char* dst = str; dst!=end; dst++)
|
||||
inc.z dst
|
||||
bne !+
|
||||
inc.z dst+1
|
||||
!:
|
||||
jmp __b2
|
||||
}
|
||||
// Copy block of memory (forwards)
|
||||
// Copies the values of num bytes from the location pointed to by source directly to the memory block pointed to by destination.
|
||||
// memcpy(void* zp($10) destination, void* zp($b) source)
|
||||
memcpy: {
|
||||
.label src_end = $19
|
||||
.label dst = $10
|
||||
.label src = $b
|
||||
.label source = $b
|
||||
.label destination = $10
|
||||
// src_end = (char*)source+num
|
||||
lda.z source
|
||||
clc
|
||||
adc #<$19*$28-$28
|
||||
sta.z src_end
|
||||
lda.z source+1
|
||||
adc #>$19*$28-$28
|
||||
sta.z src_end+1
|
||||
__b1:
|
||||
// while(src!=src_end)
|
||||
lda.z src+1
|
||||
cmp.z src_end+1
|
||||
bne __b2
|
||||
lda.z src
|
||||
cmp.z src_end
|
||||
bne __b2
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// *dst++ = *src++
|
||||
ldy #0
|
||||
lda (src),y
|
||||
sta (dst),y
|
||||
// *dst++ = *src++;
|
||||
inc.z dst
|
||||
bne !+
|
||||
inc.z dst+1
|
||||
!:
|
||||
inc.z src
|
||||
bne !+
|
||||
inc.z src+1
|
||||
!:
|
||||
jmp __b1
|
||||
}
|
||||
// Print an unsigned char using a specific format
|
||||
// printf_uchar(byte register(X) uvalue)
|
||||
printf_uchar: {
|
||||
// printf_buffer.sign = format.sign_always?'+':0
|
||||
// Handle any sign
|
||||
lda #0
|
||||
sta printf_buffer
|
||||
// uctoa(uvalue, printf_buffer.digits, format.radix)
|
||||
// Format number into buffer
|
||||
jsr uctoa
|
||||
// printf_number_buffer(printf_buffer, format)
|
||||
lda printf_buffer
|
||||
sta.z printf_number_buffer.buffer_sign
|
||||
// Print using format
|
||||
lda #0
|
||||
sta.z printf_number_buffer.format_upper_case
|
||||
sta.z printf_number_buffer.format_zero_padding
|
||||
sta.z printf_number_buffer.format_justify_left
|
||||
tax
|
||||
jsr printf_number_buffer
|
||||
// }
|
||||
rts
|
||||
}
|
||||
// Print the contents of the number buffer using a specific format.
|
||||
// This handles minimum length, zero-filling, and left/right justification from the format
|
||||
// printf_number_buffer(byte zp($d) buffer_sign, byte register(X) format_min_length, byte zp(9) format_justify_left, byte zp($a) format_zero_padding, byte zp($18) format_upper_case)
|
||||
printf_number_buffer: {
|
||||
.label __19 = $b
|
||||
.label buffer_sign = $d
|
||||
.label padding = 5
|
||||
.label format_zero_padding = $a
|
||||
.label format_justify_left = 9
|
||||
.label format_upper_case = $18
|
||||
// if(format.min_length)
|
||||
cpx #0
|
||||
beq __b6
|
||||
// strlen(buffer.digits)
|
||||
jsr strlen
|
||||
// strlen(buffer.digits)
|
||||
// len = (signed char)strlen(buffer.digits)
|
||||
// There is a minimum length - work out the padding
|
||||
lda.z __19
|
||||
tay
|
||||
// if(buffer.sign)
|
||||
lda #0
|
||||
cmp.z buffer_sign
|
||||
beq __b13
|
||||
// len++;
|
||||
iny
|
||||
__b13:
|
||||
// padding = (signed char)format.min_length - len
|
||||
txa
|
||||
sty.z $ff
|
||||
sec
|
||||
sbc.z $ff
|
||||
sta.z padding
|
||||
// if(padding<0)
|
||||
cmp #0
|
||||
bpl __b1
|
||||
__b6:
|
||||
lda #0
|
||||
sta.z padding
|
||||
__b1:
|
||||
// if(!format.justify_left && !format.zero_padding && padding)
|
||||
lda #0
|
||||
cmp.z format_justify_left
|
||||
bne __b2
|
||||
cmp.z format_zero_padding
|
||||
bne __b2
|
||||
cmp.z padding
|
||||
bne __b8
|
||||
jmp __b2
|
||||
__b8:
|
||||
// printf_padding(' ',(char)padding)
|
||||
lda.z padding
|
||||
sta.z printf_padding.length
|
||||
lda #' '
|
||||
sta.z printf_padding.pad
|
||||
jsr printf_padding
|
||||
__b2:
|
||||
// if(buffer.sign)
|
||||
lda #0
|
||||
cmp.z buffer_sign
|
||||
beq __b3
|
||||
// cputc(buffer.sign)
|
||||
lda.z buffer_sign
|
||||
jsr cputc
|
||||
__b3:
|
||||
// if(format.zero_padding && padding)
|
||||
lda #0
|
||||
cmp.z format_zero_padding
|
||||
beq __b4
|
||||
cmp.z padding
|
||||
bne __b10
|
||||
jmp __b4
|
||||
__b10:
|
||||
// printf_padding('0',(char)padding)
|
||||
lda.z padding
|
||||
sta.z printf_padding.length
|
||||
lda #'0'
|
||||
sta.z printf_padding.pad
|
||||
jsr printf_padding
|
||||
__b4:
|
||||
// if(format.upper_case)
|
||||
lda #0
|
||||
cmp.z format_upper_case
|
||||
beq __b5
|
||||
// strupr(buffer.digits)
|
||||
jsr strupr
|
||||
__b5:
|
||||
// cputs(buffer.digits)
|
||||
lda #<printf_buffer+OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
sta.z cputs.s
|
||||
lda #>printf_buffer+OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
sta.z cputs.s+1
|
||||
jsr cputs
|
||||
// if(format.justify_left && !format.zero_padding && padding)
|
||||
lda #0
|
||||
cmp.z format_justify_left
|
||||
beq __breturn
|
||||
cmp.z format_zero_padding
|
||||
bne __breturn
|
||||
cmp.z padding
|
||||
bne __b12
|
||||
rts
|
||||
__b12:
|
||||
// printf_padding(' ',(char)padding)
|
||||
lda.z padding
|
||||
sta.z printf_padding.length
|
||||
lda #' '
|
||||
sta.z printf_padding.pad
|
||||
jsr printf_padding
|
||||
__breturn:
|
||||
// }
|
||||
rts
|
||||
}
|
||||
// Print a padding char a number of times
|
||||
// printf_padding(byte zp(7) pad, byte zp(6) length)
|
||||
printf_padding: {
|
||||
.label i = 8
|
||||
.label length = 6
|
||||
.label pad = 7
|
||||
lda #0
|
||||
sta.z i
|
||||
__b1:
|
||||
// for(char i=0;i<length; i++)
|
||||
lda.z i
|
||||
cmp.z length
|
||||
bcc __b2
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// cputc(pad)
|
||||
lda.z pad
|
||||
jsr cputc
|
||||
// for(char i=0;i<length; i++)
|
||||
inc.z i
|
||||
jmp __b1
|
||||
}
|
||||
// Converts a string to uppercase.
|
||||
strupr: {
|
||||
.label str = printf_buffer+OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
.label src = $e
|
||||
lda #<str
|
||||
sta.z src
|
||||
lda #>str
|
||||
sta.z src+1
|
||||
__b1:
|
||||
// while(*src)
|
||||
ldy #0
|
||||
lda (src),y
|
||||
cmp #0
|
||||
bne __b2
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// toupper(*src)
|
||||
ldy #0
|
||||
lda (src),y
|
||||
jsr toupper
|
||||
// *src = toupper(*src)
|
||||
ldy #0
|
||||
sta (src),y
|
||||
// src++;
|
||||
inc.z src
|
||||
bne !+
|
||||
inc.z src+1
|
||||
!:
|
||||
jmp __b1
|
||||
}
|
||||
// Convert lowercase alphabet to uppercase
|
||||
// Returns uppercase equivalent to c, if such value exists, else c remains unchanged
|
||||
// toupper(byte register(A) ch)
|
||||
toupper: {
|
||||
// if(ch>='a' && ch<='z')
|
||||
cmp #'a'
|
||||
bcc __breturn
|
||||
cmp #'z'
|
||||
bcc __b1
|
||||
beq __b1
|
||||
rts
|
||||
__b1:
|
||||
// return ch + ('A'-'a');
|
||||
clc
|
||||
adc #'A'-'a'
|
||||
__breturn:
|
||||
// }
|
||||
rts
|
||||
}
|
||||
// Computes the length of the string str up to but not including the terminating null character.
|
||||
// strlen(byte* zp($10) str)
|
||||
strlen: {
|
||||
.label len = $b
|
||||
.label str = $10
|
||||
.label return = $b
|
||||
lda #<0
|
||||
sta.z len
|
||||
sta.z len+1
|
||||
lda #<printf_buffer+OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
sta.z str
|
||||
lda #>printf_buffer+OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
sta.z str+1
|
||||
__b1:
|
||||
// while(*str)
|
||||
ldy #0
|
||||
lda (str),y
|
||||
cmp #0
|
||||
bne __b2
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// len++;
|
||||
inc.z len
|
||||
bne !+
|
||||
inc.z len+1
|
||||
!:
|
||||
// str++;
|
||||
inc.z str
|
||||
bne !+
|
||||
inc.z str+1
|
||||
!:
|
||||
jmp __b1
|
||||
}
|
||||
// Converts unsigned number value to a string representing it in RADIX format.
|
||||
// If the leading digits are zero they are not included in the string.
|
||||
// - value : The number to be converted to RADIX
|
||||
// - buffer : receives the string representing the number and zero-termination.
|
||||
// - radix : The radix to convert the number to (from the enum RADIX)
|
||||
// uctoa(byte register(X) value, byte* zp($b) buffer)
|
||||
uctoa: {
|
||||
.label digit_value = $18
|
||||
.label buffer = $b
|
||||
.label digit = 9
|
||||
.label started = $a
|
||||
lda #<printf_buffer+OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
sta.z buffer
|
||||
lda #>printf_buffer+OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
sta.z buffer+1
|
||||
lda #0
|
||||
sta.z started
|
||||
sta.z digit
|
||||
__b1:
|
||||
// for( char digit=0; digit<max_digits-1; digit++ )
|
||||
lda.z digit
|
||||
cmp #3-1
|
||||
bcc __b2
|
||||
// *buffer++ = DIGITS[(char)value]
|
||||
lda DIGITS,x
|
||||
ldy #0
|
||||
sta (buffer),y
|
||||
// *buffer++ = DIGITS[(char)value];
|
||||
inc.z buffer
|
||||
bne !+
|
||||
inc.z buffer+1
|
||||
!:
|
||||
// *buffer = 0
|
||||
lda #0
|
||||
tay
|
||||
sta (buffer),y
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// digit_value = digit_values[digit]
|
||||
ldy.z digit
|
||||
lda RADIX_DECIMAL_VALUES_CHAR,y
|
||||
sta.z digit_value
|
||||
// if (started || value >= digit_value)
|
||||
lda #0
|
||||
cmp.z started
|
||||
bne __b5
|
||||
cpx.z digit_value
|
||||
bcs __b5
|
||||
__b4:
|
||||
// for( char digit=0; digit<max_digits-1; digit++ )
|
||||
inc.z digit
|
||||
jmp __b1
|
||||
__b5:
|
||||
// uctoa_append(buffer++, value, digit_value)
|
||||
jsr uctoa_append
|
||||
// uctoa_append(buffer++, value, digit_value)
|
||||
// value = uctoa_append(buffer++, value, digit_value)
|
||||
// value = uctoa_append(buffer++, value, digit_value);
|
||||
inc.z buffer
|
||||
bne !+
|
||||
inc.z buffer+1
|
||||
!:
|
||||
lda #1
|
||||
sta.z started
|
||||
jmp __b4
|
||||
}
|
||||
// Used to convert a single digit of an unsigned number value to a string representation
|
||||
// Counts a single digit up from '0' as long as the value is larger than sub.
|
||||
// Each time the digit is increased sub is subtracted from value.
|
||||
// - buffer : pointer to the char that receives the digit
|
||||
// - value : The value where the digit will be derived from
|
||||
// - sub : the value of a '1' in the digit. Subtracted continually while the digit is increased.
|
||||
// (For decimal the subs used are 10000, 1000, 100, 10, 1)
|
||||
// returns : the value reduced by sub * digit so that it is less than sub.
|
||||
// uctoa_append(byte* zp($b) buffer, byte register(X) value, byte zp($18) sub)
|
||||
uctoa_append: {
|
||||
.label buffer = $b
|
||||
.label sub = $18
|
||||
ldy #0
|
||||
__b1:
|
||||
// while (value >= sub)
|
||||
cpx.z sub
|
||||
bcs __b2
|
||||
// *buffer = DIGITS[digit]
|
||||
lda DIGITS,y
|
||||
ldy #0
|
||||
sta (buffer),y
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// digit++;
|
||||
iny
|
||||
// value -= sub
|
||||
txa
|
||||
sec
|
||||
sbc.z sub
|
||||
tax
|
||||
jmp __b1
|
||||
}
|
||||
// Print an unsigned int using a specific format
|
||||
// printf_uint(word zp($e) uvalue)
|
||||
printf_uint: {
|
||||
.const format_min_length = 0
|
||||
.const format_justify_left = 0
|
||||
.const format_zero_padding = 0
|
||||
.const format_upper_case = 0
|
||||
.label uvalue = $e
|
||||
// printf_buffer.sign = format.sign_always?'+':0
|
||||
// Handle any sign
|
||||
lda #0
|
||||
sta printf_buffer
|
||||
// utoa(uvalue, printf_buffer.digits, format.radix)
|
||||
// Format number into buffer
|
||||
jsr utoa
|
||||
// printf_number_buffer(printf_buffer, format)
|
||||
lda printf_buffer
|
||||
sta.z printf_number_buffer.buffer_sign
|
||||
// Print using format
|
||||
lda #format_upper_case
|
||||
sta.z printf_number_buffer.format_upper_case
|
||||
lda #format_zero_padding
|
||||
sta.z printf_number_buffer.format_zero_padding
|
||||
lda #format_justify_left
|
||||
sta.z printf_number_buffer.format_justify_left
|
||||
ldx #format_min_length
|
||||
jsr printf_number_buffer
|
||||
// }
|
||||
rts
|
||||
}
|
||||
// Converts unsigned number value to a string representing it in RADIX format.
|
||||
// If the leading digits are zero they are not included in the string.
|
||||
// - value : The number to be converted to RADIX
|
||||
// - buffer : receives the string representing the number and zero-termination.
|
||||
// - radix : The radix to convert the number to (from the enum RADIX)
|
||||
// utoa(word zp($e) value, byte* zp($10) buffer)
|
||||
utoa: {
|
||||
.const max_digits = 4
|
||||
.label digit_value = $19
|
||||
.label buffer = $10
|
||||
.label digit = $d
|
||||
.label value = $e
|
||||
lda #<printf_buffer+OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
sta.z buffer
|
||||
lda #>printf_buffer+OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
sta.z buffer+1
|
||||
ldx #0
|
||||
txa
|
||||
sta.z digit
|
||||
__b1:
|
||||
// for( char digit=0; digit<max_digits-1; digit++ )
|
||||
lda.z digit
|
||||
cmp #max_digits-1
|
||||
bcc __b2
|
||||
// *buffer++ = DIGITS[(char)value]
|
||||
lda.z value
|
||||
tay
|
||||
lda DIGITS,y
|
||||
ldy #0
|
||||
sta (buffer),y
|
||||
// *buffer++ = DIGITS[(char)value];
|
||||
inc.z buffer
|
||||
bne !+
|
||||
inc.z buffer+1
|
||||
!:
|
||||
// *buffer = 0
|
||||
lda #0
|
||||
tay
|
||||
sta (buffer),y
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// digit_value = digit_values[digit]
|
||||
lda.z digit
|
||||
asl
|
||||
tay
|
||||
lda RADIX_HEXADECIMAL_VALUES,y
|
||||
sta.z digit_value
|
||||
lda RADIX_HEXADECIMAL_VALUES+1,y
|
||||
sta.z digit_value+1
|
||||
// if (started || value >= digit_value)
|
||||
cpx #0
|
||||
bne __b5
|
||||
cmp.z value+1
|
||||
bne !+
|
||||
lda.z digit_value
|
||||
cmp.z value
|
||||
beq __b5
|
||||
!:
|
||||
bcc __b5
|
||||
__b4:
|
||||
// for( char digit=0; digit<max_digits-1; digit++ )
|
||||
inc.z digit
|
||||
jmp __b1
|
||||
__b5:
|
||||
// utoa_append(buffer++, value, digit_value)
|
||||
jsr utoa_append
|
||||
// utoa_append(buffer++, value, digit_value)
|
||||
// value = utoa_append(buffer++, value, digit_value)
|
||||
// value = utoa_append(buffer++, value, digit_value);
|
||||
inc.z buffer
|
||||
bne !+
|
||||
inc.z buffer+1
|
||||
!:
|
||||
ldx #1
|
||||
jmp __b4
|
||||
}
|
||||
// Used to convert a single digit of an unsigned number value to a string representation
|
||||
// Counts a single digit up from '0' as long as the value is larger than sub.
|
||||
// Each time the digit is increased sub is subtracted from value.
|
||||
// - buffer : pointer to the char that receives the digit
|
||||
// - value : The value where the digit will be derived from
|
||||
// - sub : the value of a '1' in the digit. Subtracted continually while the digit is increased.
|
||||
// (For decimal the subs used are 10000, 1000, 100, 10, 1)
|
||||
// returns : the value reduced by sub * digit so that it is less than sub.
|
||||
// utoa_append(byte* zp($10) buffer, word zp($e) value, word zp($19) sub)
|
||||
utoa_append: {
|
||||
.label buffer = $10
|
||||
.label value = $e
|
||||
.label sub = $19
|
||||
.label return = $e
|
||||
ldx #0
|
||||
__b1:
|
||||
// while (value >= sub)
|
||||
lda.z sub+1
|
||||
cmp.z value+1
|
||||
bne !+
|
||||
lda.z sub
|
||||
cmp.z value
|
||||
beq __b2
|
||||
!:
|
||||
bcc __b2
|
||||
// *buffer = DIGITS[digit]
|
||||
lda DIGITS,x
|
||||
ldy #0
|
||||
sta (buffer),y
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// digit++;
|
||||
inx
|
||||
// value -= sub
|
||||
lda.z value
|
||||
sec
|
||||
sbc.z sub
|
||||
sta.z value
|
||||
lda.z value+1
|
||||
sbc.z sub+1
|
||||
sta.z value+1
|
||||
jmp __b1
|
||||
}
|
||||
// clears the screen and moves the cursor to the upper left-hand corner of the screen.
|
||||
clrscr: {
|
||||
.label line_text = $e
|
||||
.label line_cols = $10
|
||||
lda #<CONIO_SCREEN_COLORS
|
||||
sta.z line_cols
|
||||
lda #>CONIO_SCREEN_COLORS
|
||||
sta.z line_cols+1
|
||||
lda #<CONIO_SCREEN_TEXT
|
||||
sta.z line_text
|
||||
lda #>CONIO_SCREEN_TEXT
|
||||
sta.z line_text+1
|
||||
ldx #0
|
||||
__b1:
|
||||
// for( char l=0;l<CONIO_HEIGHT; l++ )
|
||||
cpx #$19
|
||||
bcc __b2
|
||||
// conio_cursor_x = 0
|
||||
lda #0
|
||||
sta.z conio_cursor_x
|
||||
// conio_cursor_y = 0
|
||||
sta.z conio_cursor_y
|
||||
// conio_cursor_text = CONIO_SCREEN_TEXT
|
||||
lda #<CONIO_SCREEN_TEXT
|
||||
sta.z conio_cursor_text
|
||||
lda #>CONIO_SCREEN_TEXT
|
||||
sta.z conio_cursor_text+1
|
||||
// conio_cursor_color = CONIO_SCREEN_COLORS
|
||||
lda #<CONIO_SCREEN_COLORS
|
||||
sta.z conio_cursor_color
|
||||
lda #>CONIO_SCREEN_COLORS
|
||||
sta.z conio_cursor_color+1
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
ldy #0
|
||||
__b3:
|
||||
// for( char c=0;c<CONIO_WIDTH; c++ )
|
||||
cpy #$28
|
||||
bcc __b4
|
||||
// line_text += CONIO_WIDTH
|
||||
lda #$28
|
||||
clc
|
||||
adc.z line_text
|
||||
sta.z line_text
|
||||
bcc !+
|
||||
inc.z line_text+1
|
||||
!:
|
||||
// line_cols += CONIO_WIDTH
|
||||
lda #$28
|
||||
clc
|
||||
adc.z line_cols
|
||||
sta.z line_cols
|
||||
bcc !+
|
||||
inc.z line_cols+1
|
||||
!:
|
||||
// for( char l=0;l<CONIO_HEIGHT; l++ )
|
||||
inx
|
||||
jmp __b1
|
||||
__b4:
|
||||
// line_text[c] = ' '
|
||||
lda #' '
|
||||
sta (line_text),y
|
||||
// line_cols[c] = conio_textcolor
|
||||
lda #CONIO_TEXTCOLOR_DEFAULT
|
||||
sta (line_cols),y
|
||||
// for( char c=0;c<CONIO_WIDTH; c++ )
|
||||
iny
|
||||
jmp __b3
|
||||
}
|
||||
// The digits used for numbers
|
||||
DIGITS: .text "0123456789abcdef"
|
||||
// Values of decimal digits
|
||||
RADIX_DECIMAL_VALUES_CHAR: .byte $64, $a
|
||||
// Values of hexadecimal digits
|
||||
RADIX_HEXADECIMAL_VALUES: .word $1000, $100, $10
|
||||
stars: .byte $32, $32, 2, 7, $28, $46, 2, 7, $1e, $14, 2, 7, $46, $a, 2, 7, $28, $50, 2, 7
|
||||
// Buffer used for stringified number being printed
|
||||
printf_buffer: .fill SIZEOF_STRUCT_PRINTF_BUFFER_NUMBER, 0
|
553
src/test/ref/stars-1.cfg
Normal file
553
src/test/ref/stars-1.cfg
Normal file
@ -0,0 +1,553 @@
|
||||
@begin: scope:[] from
|
||||
[0] phi()
|
||||
to:@1
|
||||
@1: scope:[] from @begin
|
||||
[1] (byte) conio_cursor_x ← (byte) 0
|
||||
[2] (byte) conio_cursor_y ← (byte) 0
|
||||
[3] (byte*) conio_cursor_text ← (const nomodify byte*) CONIO_SCREEN_TEXT
|
||||
[4] (byte*) conio_cursor_color ← (const nomodify byte*) CONIO_SCREEN_COLORS
|
||||
to:@2
|
||||
@2: scope:[] from @1
|
||||
[5] phi()
|
||||
[6] call main
|
||||
to:@end
|
||||
@end: scope:[] from @2
|
||||
[7] phi()
|
||||
|
||||
(void()) main()
|
||||
main: scope:[main] from @2
|
||||
[8] phi()
|
||||
[9] call clrscr
|
||||
to:main::@1
|
||||
main::@1: scope:[main] from main main::@8
|
||||
[10] (struct $0*) main::pStar#2 ← phi( main/(const struct $0*) stars main::@8/(struct $0*) main::pStar#1 )
|
||||
[10] (byte) main::i#2 ← phi( main/(byte) 0 main::@8/(byte) main::i#1 )
|
||||
[11] if((byte) main::i#2<(byte) 5) goto main::@2
|
||||
to:main::@return
|
||||
main::@return: scope:[main] from main::@1
|
||||
[12] return
|
||||
to:@return
|
||||
main::@2: scope:[main] from main::@1
|
||||
[13] (word) printf_uint::uvalue#0 ← (word)(struct $0*) main::pStar#2
|
||||
[14] call printf_uint
|
||||
to:main::@3
|
||||
main::@3: scope:[main] from main::@2
|
||||
[15] phi()
|
||||
[16] call cputs
|
||||
to:main::@4
|
||||
main::@4: scope:[main] from main::@3
|
||||
[17] (byte) printf_uchar::uvalue#0 ← *((byte*)(struct $0*) main::pStar#2)
|
||||
[18] call printf_uchar
|
||||
to:main::@5
|
||||
main::@5: scope:[main] from main::@4
|
||||
[19] phi()
|
||||
[20] call cputs
|
||||
to:main::@6
|
||||
main::@6: scope:[main] from main::@5
|
||||
[21] (byte) printf_uchar::uvalue#1 ← *((byte*)(struct $0*) main::pStar#2 + (byte) 1)
|
||||
[22] call printf_uchar
|
||||
to:main::@7
|
||||
main::@7: scope:[main] from main::@6
|
||||
[23] phi()
|
||||
[24] call cputs
|
||||
to:main::@8
|
||||
main::@8: scope:[main] from main::@7
|
||||
[25] (struct $0*) main::pStar#1 ← (struct $0*) main::pStar#2 + (byte) 4
|
||||
[26] (byte) main::i#1 ← ++ (byte) main::i#2
|
||||
to:main::@1
|
||||
|
||||
(void()) cputs((to_nomodify byte*) cputs::s)
|
||||
cputs: scope:[cputs] from main::@3 main::@5 main::@7 printf_number_buffer::@5
|
||||
[27] (to_nomodify byte*) cputs::s#6 ← phi( main::@3/(const byte*) main::s main::@5/(const byte*) main::s main::@7/(const byte*) main::s2 printf_number_buffer::@5/(byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS )
|
||||
to:cputs::@1
|
||||
cputs::@1: scope:[cputs] from cputs cputs::@2
|
||||
[28] (to_nomodify byte*) cputs::s#5 ← phi( cputs/(to_nomodify byte*) cputs::s#6 cputs::@2/(to_nomodify byte*) cputs::s#0 )
|
||||
[29] (byte) cputs::c#1 ← *((to_nomodify byte*) cputs::s#5)
|
||||
[30] (to_nomodify byte*) cputs::s#0 ← ++ (to_nomodify byte*) cputs::s#5
|
||||
[31] if((byte) 0!=(byte) cputs::c#1) goto cputs::@2
|
||||
to:cputs::@return
|
||||
cputs::@return: scope:[cputs] from cputs::@1
|
||||
[32] return
|
||||
to:@return
|
||||
cputs::@2: scope:[cputs] from cputs::@1
|
||||
[33] (byte) cputc::c#0 ← (byte) cputs::c#1
|
||||
[34] call cputc
|
||||
to:cputs::@1
|
||||
|
||||
(void()) cputc((byte) cputc::c)
|
||||
cputc: scope:[cputc] from cputs::@2 printf_number_buffer::@9 printf_padding::@2
|
||||
[35] (byte) cputc::c#3 ← phi( cputs::@2/(byte) cputc::c#0 printf_number_buffer::@9/(byte) cputc::c#2 printf_padding::@2/(byte) cputc::c#1 )
|
||||
[36] if((byte) cputc::c#3==(byte) '
|
||||
') goto cputc::@1
|
||||
to:cputc::@2
|
||||
cputc::@2: scope:[cputc] from cputc
|
||||
[37] *((byte*) conio_cursor_text) ← (byte) cputc::c#3
|
||||
[38] (byte*) conio_cursor_text ← ++ (byte*) conio_cursor_text
|
||||
[39] *((byte*) conio_cursor_color) ← (const nomodify byte) CONIO_TEXTCOLOR_DEFAULT
|
||||
[40] (byte*) conio_cursor_color ← ++ (byte*) conio_cursor_color
|
||||
[41] (byte) conio_cursor_x ← ++ (byte) conio_cursor_x
|
||||
[42] if((byte) conio_cursor_x!=(byte) $28) goto cputc::@return
|
||||
to:cputc::@3
|
||||
cputc::@3: scope:[cputc] from cputc::@2
|
||||
[43] (byte) conio_cursor_x ← (byte) 0
|
||||
[44] (byte) conio_cursor_y ← ++ (byte) conio_cursor_y
|
||||
[45] call cscroll
|
||||
to:cputc::@return
|
||||
cputc::@return: scope:[cputc] from cputc::@1 cputc::@2 cputc::@3
|
||||
[46] return
|
||||
to:@return
|
||||
cputc::@1: scope:[cputc] from cputc
|
||||
[47] phi()
|
||||
[48] call cputln
|
||||
to:cputc::@return
|
||||
|
||||
(void()) cputln()
|
||||
cputln: scope:[cputln] from cputc::@1
|
||||
[49] (byte*~) cputln::$0 ← (byte*) conio_cursor_text - (byte) conio_cursor_x
|
||||
[50] (byte*~) cputln::$1 ← (byte*~) cputln::$0 + (byte) $28
|
||||
[51] (byte*) conio_cursor_text ← (byte*~) cputln::$1
|
||||
[52] (byte*~) cputln::$2 ← (byte*) conio_cursor_color - (byte) conio_cursor_x
|
||||
[53] (byte*~) cputln::$3 ← (byte*~) cputln::$2 + (byte) $28
|
||||
[54] (byte*) conio_cursor_color ← (byte*~) cputln::$3
|
||||
[55] (byte) conio_cursor_x ← (byte) 0
|
||||
[56] (byte) conio_cursor_y ← ++ (byte) conio_cursor_y
|
||||
[57] call cscroll
|
||||
to:cputln::@return
|
||||
cputln::@return: scope:[cputln] from cputln
|
||||
[58] return
|
||||
to:@return
|
||||
|
||||
(void()) cscroll()
|
||||
cscroll: scope:[cscroll] from cputc::@3 cputln
|
||||
[59] if((byte) conio_cursor_y!=(byte) $19) goto cscroll::@return
|
||||
to:cscroll::@1
|
||||
cscroll::@1: scope:[cscroll] from cscroll
|
||||
[60] phi()
|
||||
[61] call memcpy
|
||||
to:cscroll::@2
|
||||
cscroll::@2: scope:[cscroll] from cscroll::@1
|
||||
[62] phi()
|
||||
[63] call memcpy
|
||||
to:cscroll::@3
|
||||
cscroll::@3: scope:[cscroll] from cscroll::@2
|
||||
[64] phi()
|
||||
[65] call memset
|
||||
to:cscroll::@4
|
||||
cscroll::@4: scope:[cscroll] from cscroll::@3
|
||||
[66] phi()
|
||||
[67] call memset
|
||||
to:cscroll::@5
|
||||
cscroll::@5: scope:[cscroll] from cscroll::@4
|
||||
[68] (byte*~) cscroll::$7 ← (byte*) conio_cursor_text - (byte) $28
|
||||
[69] (byte*) conio_cursor_text ← (byte*~) cscroll::$7
|
||||
[70] (byte*~) cscroll::$8 ← (byte*) conio_cursor_color - (byte) $28
|
||||
[71] (byte*) conio_cursor_color ← (byte*~) cscroll::$8
|
||||
[72] (byte) conio_cursor_y ← -- (byte) conio_cursor_y
|
||||
to:cscroll::@return
|
||||
cscroll::@return: scope:[cscroll] from cscroll cscroll::@5
|
||||
[73] return
|
||||
to:@return
|
||||
|
||||
(void*()) memset((void*) memset::str , (byte) memset::c , (word) memset::num)
|
||||
memset: scope:[memset] from cscroll::@3 cscroll::@4
|
||||
[74] (byte) memset::c#4 ← phi( cscroll::@3/(byte) ' ' cscroll::@4/(const nomodify byte) CONIO_TEXTCOLOR_DEFAULT )
|
||||
[74] (void*) memset::str#3 ← phi( cscroll::@3/(void*)(const nomodify byte*) CONIO_SCREEN_TEXT+(word)(number) $19*(number) $28-(byte) $28 cscroll::@4/(void*)(const nomodify byte*) CONIO_SCREEN_COLORS+(word)(number) $19*(number) $28-(byte) $28 )
|
||||
to:memset::@1
|
||||
memset::@1: scope:[memset] from memset
|
||||
[75] (byte*) memset::end#0 ← (byte*)(void*) memset::str#3 + (byte) $28
|
||||
[76] (byte*) memset::dst#4 ← (byte*)(void*) memset::str#3
|
||||
to:memset::@2
|
||||
memset::@2: scope:[memset] from memset::@1 memset::@3
|
||||
[77] (byte*) memset::dst#2 ← phi( memset::@1/(byte*) memset::dst#4 memset::@3/(byte*) memset::dst#1 )
|
||||
[78] if((byte*) memset::dst#2!=(byte*) memset::end#0) goto memset::@3
|
||||
to:memset::@return
|
||||
memset::@return: scope:[memset] from memset::@2
|
||||
[79] return
|
||||
to:@return
|
||||
memset::@3: scope:[memset] from memset::@2
|
||||
[80] *((byte*) memset::dst#2) ← (byte) memset::c#4
|
||||
[81] (byte*) memset::dst#1 ← ++ (byte*) memset::dst#2
|
||||
to:memset::@2
|
||||
|
||||
(void*()) memcpy((void*) memcpy::destination , (void*) memcpy::source , (word) memcpy::num)
|
||||
memcpy: scope:[memcpy] from cscroll::@1 cscroll::@2
|
||||
[82] (void*) memcpy::destination#2 ← phi( cscroll::@1/(void*)(const nomodify byte*) CONIO_SCREEN_TEXT cscroll::@2/(void*)(const nomodify byte*) CONIO_SCREEN_COLORS )
|
||||
[82] (void*) memcpy::source#2 ← phi( cscroll::@1/(void*)(const nomodify byte*) CONIO_SCREEN_TEXT+(byte) $28 cscroll::@2/(void*)(const nomodify byte*) CONIO_SCREEN_COLORS+(byte) $28 )
|
||||
[83] (byte*) memcpy::src_end#0 ← (byte*)(void*) memcpy::source#2 + (word)(number) $19*(number) $28-(number) $28
|
||||
[84] (byte*) memcpy::src#4 ← (byte*)(void*) memcpy::source#2
|
||||
[85] (byte*) memcpy::dst#4 ← (byte*)(void*) memcpy::destination#2
|
||||
to:memcpy::@1
|
||||
memcpy::@1: scope:[memcpy] from memcpy memcpy::@2
|
||||
[86] (byte*) memcpy::dst#2 ← phi( memcpy/(byte*) memcpy::dst#4 memcpy::@2/(byte*) memcpy::dst#1 )
|
||||
[86] (byte*) memcpy::src#2 ← phi( memcpy/(byte*) memcpy::src#4 memcpy::@2/(byte*) memcpy::src#1 )
|
||||
[87] if((byte*) memcpy::src#2!=(byte*) memcpy::src_end#0) goto memcpy::@2
|
||||
to:memcpy::@return
|
||||
memcpy::@return: scope:[memcpy] from memcpy::@1
|
||||
[88] return
|
||||
to:@return
|
||||
memcpy::@2: scope:[memcpy] from memcpy::@1
|
||||
[89] *((byte*) memcpy::dst#2) ← *((byte*) memcpy::src#2)
|
||||
[90] (byte*) memcpy::dst#1 ← ++ (byte*) memcpy::dst#2
|
||||
[91] (byte*) memcpy::src#1 ← ++ (byte*) memcpy::src#2
|
||||
to:memcpy::@1
|
||||
|
||||
(void()) printf_uchar((byte) printf_uchar::uvalue , (byte) printf_uchar::format_min_length , (byte) printf_uchar::format_justify_left , (byte) printf_uchar::format_sign_always , (byte) printf_uchar::format_zero_padding , (byte) printf_uchar::format_upper_case , (byte) printf_uchar::format_radix)
|
||||
printf_uchar: scope:[printf_uchar] from main::@4 main::@6
|
||||
[92] (byte) printf_uchar::uvalue#2 ← phi( main::@4/(byte) printf_uchar::uvalue#0 main::@6/(byte) printf_uchar::uvalue#1 )
|
||||
to:printf_uchar::@1
|
||||
printf_uchar::@1: scope:[printf_uchar] from printf_uchar
|
||||
[93] *((byte*)&(struct printf_buffer_number) printf_buffer) ← (byte) 0
|
||||
[94] (byte) uctoa::value#1 ← (byte) printf_uchar::uvalue#2
|
||||
[95] call uctoa
|
||||
to:printf_uchar::@2
|
||||
printf_uchar::@2: scope:[printf_uchar] from printf_uchar::@1
|
||||
[96] (byte) printf_number_buffer::buffer_sign#1 ← *((byte*)&(struct printf_buffer_number) printf_buffer)
|
||||
[97] call printf_number_buffer
|
||||
to:printf_uchar::@return
|
||||
printf_uchar::@return: scope:[printf_uchar] from printf_uchar::@2
|
||||
[98] return
|
||||
to:@return
|
||||
|
||||
(void()) printf_number_buffer((byte) printf_number_buffer::buffer_sign , (byte*) printf_number_buffer::buffer_digits , (byte) printf_number_buffer::format_min_length , (byte) printf_number_buffer::format_justify_left , (byte) printf_number_buffer::format_sign_always , (byte) printf_number_buffer::format_zero_padding , (byte) printf_number_buffer::format_upper_case , (byte) printf_number_buffer::format_radix)
|
||||
printf_number_buffer: scope:[printf_number_buffer] from printf_uchar::@2 printf_uint::@2
|
||||
[99] (byte) printf_number_buffer::format_upper_case#10 ← phi( printf_uchar::@2/(byte) 0 printf_uint::@2/(const byte) printf_uint::format_upper_case#0 )
|
||||
[99] (byte) printf_number_buffer::buffer_sign#10 ← phi( printf_uchar::@2/(byte) printf_number_buffer::buffer_sign#1 printf_uint::@2/(byte) printf_number_buffer::buffer_sign#0 )
|
||||
[99] (byte) printf_number_buffer::format_zero_padding#10 ← phi( printf_uchar::@2/(byte) 0 printf_uint::@2/(const byte) printf_uint::format_zero_padding#0 )
|
||||
[99] (byte) printf_number_buffer::format_justify_left#10 ← phi( printf_uchar::@2/(byte) 0 printf_uint::@2/(const byte) printf_uint::format_justify_left#0 )
|
||||
[99] (byte) printf_number_buffer::format_min_length#2 ← phi( printf_uchar::@2/(byte) 0 printf_uint::@2/(const byte) printf_uint::format_min_length#0 )
|
||||
[100] if((byte) 0==(byte) printf_number_buffer::format_min_length#2) goto printf_number_buffer::@1
|
||||
to:printf_number_buffer::@6
|
||||
printf_number_buffer::@6: scope:[printf_number_buffer] from printf_number_buffer
|
||||
[101] phi()
|
||||
[102] call strlen
|
||||
[103] (word) strlen::return#2 ← (word) strlen::len#2
|
||||
to:printf_number_buffer::@14
|
||||
printf_number_buffer::@14: scope:[printf_number_buffer] from printf_number_buffer::@6
|
||||
[104] (word~) printf_number_buffer::$19 ← (word) strlen::return#2
|
||||
[105] (signed byte) printf_number_buffer::len#0 ← (signed byte)(word~) printf_number_buffer::$19
|
||||
[106] if((byte) 0==(byte) printf_number_buffer::buffer_sign#10) goto printf_number_buffer::@13
|
||||
to:printf_number_buffer::@7
|
||||
printf_number_buffer::@7: scope:[printf_number_buffer] from printf_number_buffer::@14
|
||||
[107] (signed byte) printf_number_buffer::len#1 ← ++ (signed byte) printf_number_buffer::len#0
|
||||
to:printf_number_buffer::@13
|
||||
printf_number_buffer::@13: scope:[printf_number_buffer] from printf_number_buffer::@14 printf_number_buffer::@7
|
||||
[108] (signed byte) printf_number_buffer::len#2 ← phi( printf_number_buffer::@14/(signed byte) printf_number_buffer::len#0 printf_number_buffer::@7/(signed byte) printf_number_buffer::len#1 )
|
||||
[109] (signed byte) printf_number_buffer::padding#1 ← (signed byte)(byte) printf_number_buffer::format_min_length#2 - (signed byte) printf_number_buffer::len#2
|
||||
[110] if((signed byte) printf_number_buffer::padding#1>=(signed byte) 0) goto printf_number_buffer::@21
|
||||
to:printf_number_buffer::@1
|
||||
printf_number_buffer::@21: scope:[printf_number_buffer] from printf_number_buffer::@13
|
||||
[111] phi()
|
||||
to:printf_number_buffer::@1
|
||||
printf_number_buffer::@1: scope:[printf_number_buffer] from printf_number_buffer printf_number_buffer::@13 printf_number_buffer::@21
|
||||
[112] (signed byte) printf_number_buffer::padding#10 ← phi( printf_number_buffer/(signed byte) 0 printf_number_buffer::@21/(signed byte) printf_number_buffer::padding#1 printf_number_buffer::@13/(signed byte) 0 )
|
||||
[113] if((byte) 0!=(byte) printf_number_buffer::format_justify_left#10) goto printf_number_buffer::@2
|
||||
to:printf_number_buffer::@17
|
||||
printf_number_buffer::@17: scope:[printf_number_buffer] from printf_number_buffer::@1
|
||||
[114] if((byte) 0!=(byte) printf_number_buffer::format_zero_padding#10) goto printf_number_buffer::@2
|
||||
to:printf_number_buffer::@16
|
||||
printf_number_buffer::@16: scope:[printf_number_buffer] from printf_number_buffer::@17
|
||||
[115] if((signed byte) 0!=(signed byte) printf_number_buffer::padding#10) goto printf_number_buffer::@8
|
||||
to:printf_number_buffer::@2
|
||||
printf_number_buffer::@8: scope:[printf_number_buffer] from printf_number_buffer::@16
|
||||
[116] (byte) printf_padding::length#0 ← (byte)(signed byte) printf_number_buffer::padding#10
|
||||
[117] call printf_padding
|
||||
to:printf_number_buffer::@2
|
||||
printf_number_buffer::@2: scope:[printf_number_buffer] from printf_number_buffer::@1 printf_number_buffer::@16 printf_number_buffer::@17 printf_number_buffer::@8
|
||||
[118] if((byte) 0==(byte) printf_number_buffer::buffer_sign#10) goto printf_number_buffer::@3
|
||||
to:printf_number_buffer::@9
|
||||
printf_number_buffer::@9: scope:[printf_number_buffer] from printf_number_buffer::@2
|
||||
[119] (byte) cputc::c#2 ← (byte) printf_number_buffer::buffer_sign#10
|
||||
[120] call cputc
|
||||
to:printf_number_buffer::@3
|
||||
printf_number_buffer::@3: scope:[printf_number_buffer] from printf_number_buffer::@2 printf_number_buffer::@9
|
||||
[121] if((byte) 0==(byte) printf_number_buffer::format_zero_padding#10) goto printf_number_buffer::@4
|
||||
to:printf_number_buffer::@18
|
||||
printf_number_buffer::@18: scope:[printf_number_buffer] from printf_number_buffer::@3
|
||||
[122] if((signed byte) 0!=(signed byte) printf_number_buffer::padding#10) goto printf_number_buffer::@10
|
||||
to:printf_number_buffer::@4
|
||||
printf_number_buffer::@10: scope:[printf_number_buffer] from printf_number_buffer::@18
|
||||
[123] (byte) printf_padding::length#1 ← (byte)(signed byte) printf_number_buffer::padding#10
|
||||
[124] call printf_padding
|
||||
to:printf_number_buffer::@4
|
||||
printf_number_buffer::@4: scope:[printf_number_buffer] from printf_number_buffer::@10 printf_number_buffer::@18 printf_number_buffer::@3
|
||||
[125] if((byte) 0==(byte) printf_number_buffer::format_upper_case#10) goto printf_number_buffer::@5
|
||||
to:printf_number_buffer::@11
|
||||
printf_number_buffer::@11: scope:[printf_number_buffer] from printf_number_buffer::@4
|
||||
[126] phi()
|
||||
[127] call strupr
|
||||
to:printf_number_buffer::@5
|
||||
printf_number_buffer::@5: scope:[printf_number_buffer] from printf_number_buffer::@11 printf_number_buffer::@4
|
||||
[128] phi()
|
||||
[129] call cputs
|
||||
to:printf_number_buffer::@15
|
||||
printf_number_buffer::@15: scope:[printf_number_buffer] from printf_number_buffer::@5
|
||||
[130] if((byte) 0==(byte) printf_number_buffer::format_justify_left#10) goto printf_number_buffer::@return
|
||||
to:printf_number_buffer::@20
|
||||
printf_number_buffer::@20: scope:[printf_number_buffer] from printf_number_buffer::@15
|
||||
[131] if((byte) 0!=(byte) printf_number_buffer::format_zero_padding#10) goto printf_number_buffer::@return
|
||||
to:printf_number_buffer::@19
|
||||
printf_number_buffer::@19: scope:[printf_number_buffer] from printf_number_buffer::@20
|
||||
[132] if((signed byte) 0!=(signed byte) printf_number_buffer::padding#10) goto printf_number_buffer::@12
|
||||
to:printf_number_buffer::@return
|
||||
printf_number_buffer::@12: scope:[printf_number_buffer] from printf_number_buffer::@19
|
||||
[133] (byte) printf_padding::length#2 ← (byte)(signed byte) printf_number_buffer::padding#10
|
||||
[134] call printf_padding
|
||||
to:printf_number_buffer::@return
|
||||
printf_number_buffer::@return: scope:[printf_number_buffer] from printf_number_buffer::@12 printf_number_buffer::@15 printf_number_buffer::@19 printf_number_buffer::@20
|
||||
[135] return
|
||||
to:@return
|
||||
|
||||
(void()) printf_padding((byte) printf_padding::pad , (byte) printf_padding::length)
|
||||
printf_padding: scope:[printf_padding] from printf_number_buffer::@10 printf_number_buffer::@12 printf_number_buffer::@8
|
||||
[136] (byte) printf_padding::pad#5 ← phi( printf_number_buffer::@10/(byte) '0' printf_number_buffer::@12/(byte) ' ' printf_number_buffer::@8/(byte) ' ' )
|
||||
[136] (byte) printf_padding::length#4 ← phi( printf_number_buffer::@10/(byte) printf_padding::length#1 printf_number_buffer::@12/(byte) printf_padding::length#2 printf_number_buffer::@8/(byte) printf_padding::length#0 )
|
||||
to:printf_padding::@1
|
||||
printf_padding::@1: scope:[printf_padding] from printf_padding printf_padding::@3
|
||||
[137] (byte) printf_padding::i#2 ← phi( printf_padding/(byte) 0 printf_padding::@3/(byte) printf_padding::i#1 )
|
||||
[138] if((byte) printf_padding::i#2<(byte) printf_padding::length#4) goto printf_padding::@2
|
||||
to:printf_padding::@return
|
||||
printf_padding::@return: scope:[printf_padding] from printf_padding::@1
|
||||
[139] return
|
||||
to:@return
|
||||
printf_padding::@2: scope:[printf_padding] from printf_padding::@1
|
||||
[140] (byte) cputc::c#1 ← (byte) printf_padding::pad#5
|
||||
[141] call cputc
|
||||
to:printf_padding::@3
|
||||
printf_padding::@3: scope:[printf_padding] from printf_padding::@2
|
||||
[142] (byte) printf_padding::i#1 ← ++ (byte) printf_padding::i#2
|
||||
to:printf_padding::@1
|
||||
|
||||
(byte*()) strupr((byte*) strupr::str)
|
||||
strupr: scope:[strupr] from printf_number_buffer::@11
|
||||
[143] phi()
|
||||
to:strupr::@1
|
||||
strupr::@1: scope:[strupr] from strupr strupr::@3
|
||||
[144] (byte*) strupr::src#2 ← phi( strupr/(const byte*) strupr::str#0 strupr::@3/(byte*) strupr::src#1 )
|
||||
[145] if((byte) 0!=*((byte*) strupr::src#2)) goto strupr::@2
|
||||
to:strupr::@return
|
||||
strupr::@return: scope:[strupr] from strupr::@1
|
||||
[146] return
|
||||
to:@return
|
||||
strupr::@2: scope:[strupr] from strupr::@1
|
||||
[147] (byte) toupper::ch#0 ← *((byte*) strupr::src#2)
|
||||
[148] call toupper
|
||||
[149] (byte) toupper::return#3 ← (byte) toupper::return#2
|
||||
to:strupr::@3
|
||||
strupr::@3: scope:[strupr] from strupr::@2
|
||||
[150] (byte~) strupr::$0 ← (byte) toupper::return#3
|
||||
[151] *((byte*) strupr::src#2) ← (byte~) strupr::$0
|
||||
[152] (byte*) strupr::src#1 ← ++ (byte*) strupr::src#2
|
||||
to:strupr::@1
|
||||
|
||||
(byte()) toupper((byte) toupper::ch)
|
||||
toupper: scope:[toupper] from strupr::@2
|
||||
[153] if((byte) toupper::ch#0<(byte) 'a') goto toupper::@return
|
||||
to:toupper::@2
|
||||
toupper::@2: scope:[toupper] from toupper
|
||||
[154] if((byte) toupper::ch#0<=(byte) 'z') goto toupper::@1
|
||||
to:toupper::@return
|
||||
toupper::@1: scope:[toupper] from toupper::@2
|
||||
[155] (byte) toupper::return#0 ← (byte) toupper::ch#0 + (byte) 'A'-(byte) 'a'
|
||||
to:toupper::@return
|
||||
toupper::@return: scope:[toupper] from toupper toupper::@1 toupper::@2
|
||||
[156] (byte) toupper::return#2 ← phi( toupper::@1/(byte) toupper::return#0 toupper/(byte) toupper::ch#0 toupper::@2/(byte) toupper::ch#0 )
|
||||
[157] return
|
||||
to:@return
|
||||
|
||||
(word()) strlen((byte*) strlen::str)
|
||||
strlen: scope:[strlen] from printf_number_buffer::@6
|
||||
[158] phi()
|
||||
to:strlen::@1
|
||||
strlen::@1: scope:[strlen] from strlen strlen::@2
|
||||
[159] (word) strlen::len#2 ← phi( strlen/(word) 0 strlen::@2/(word) strlen::len#1 )
|
||||
[159] (byte*) strlen::str#2 ← phi( strlen/(byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS strlen::@2/(byte*) strlen::str#0 )
|
||||
[160] if((byte) 0!=*((byte*) strlen::str#2)) goto strlen::@2
|
||||
to:strlen::@return
|
||||
strlen::@return: scope:[strlen] from strlen::@1
|
||||
[161] return
|
||||
to:@return
|
||||
strlen::@2: scope:[strlen] from strlen::@1
|
||||
[162] (word) strlen::len#1 ← ++ (word) strlen::len#2
|
||||
[163] (byte*) strlen::str#0 ← ++ (byte*) strlen::str#2
|
||||
to:strlen::@1
|
||||
|
||||
(void()) uctoa((byte) uctoa::value , (byte*) uctoa::buffer , (byte) uctoa::radix)
|
||||
uctoa: scope:[uctoa] from printf_uchar::@1
|
||||
[164] phi()
|
||||
to:uctoa::@1
|
||||
uctoa::@1: scope:[uctoa] from uctoa uctoa::@4
|
||||
[165] (byte*) uctoa::buffer#11 ← phi( uctoa::@4/(byte*) uctoa::buffer#14 uctoa/(byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS )
|
||||
[165] (byte) uctoa::started#2 ← phi( uctoa::@4/(byte) uctoa::started#4 uctoa/(byte) 0 )
|
||||
[165] (byte) uctoa::value#2 ← phi( uctoa::@4/(byte) uctoa::value#6 uctoa/(byte) uctoa::value#1 )
|
||||
[165] (byte) uctoa::digit#2 ← phi( uctoa::@4/(byte) uctoa::digit#1 uctoa/(byte) 0 )
|
||||
[166] if((byte) uctoa::digit#2<(byte) 3-(byte) 1) goto uctoa::@2
|
||||
to:uctoa::@3
|
||||
uctoa::@3: scope:[uctoa] from uctoa::@1
|
||||
[167] *((byte*) uctoa::buffer#11) ← *((const byte*) DIGITS + (byte) uctoa::value#2)
|
||||
[168] (byte*) uctoa::buffer#3 ← ++ (byte*) uctoa::buffer#11
|
||||
[169] *((byte*) uctoa::buffer#3) ← (byte) 0
|
||||
to:uctoa::@return
|
||||
uctoa::@return: scope:[uctoa] from uctoa::@3
|
||||
[170] return
|
||||
to:@return
|
||||
uctoa::@2: scope:[uctoa] from uctoa::@1
|
||||
[171] (byte) uctoa::digit_value#0 ← *((const byte*) RADIX_DECIMAL_VALUES_CHAR + (byte) uctoa::digit#2)
|
||||
[172] if((byte) 0!=(byte) uctoa::started#2) goto uctoa::@5
|
||||
to:uctoa::@7
|
||||
uctoa::@7: scope:[uctoa] from uctoa::@2
|
||||
[173] if((byte) uctoa::value#2>=(byte) uctoa::digit_value#0) goto uctoa::@5
|
||||
to:uctoa::@4
|
||||
uctoa::@4: scope:[uctoa] from uctoa::@6 uctoa::@7
|
||||
[174] (byte*) uctoa::buffer#14 ← phi( uctoa::@7/(byte*) uctoa::buffer#11 uctoa::@6/(byte*) uctoa::buffer#4 )
|
||||
[174] (byte) uctoa::started#4 ← phi( uctoa::@7/(byte) uctoa::started#2 uctoa::@6/(byte) 1 )
|
||||
[174] (byte) uctoa::value#6 ← phi( uctoa::@7/(byte) uctoa::value#2 uctoa::@6/(byte) uctoa::value#0 )
|
||||
[175] (byte) uctoa::digit#1 ← ++ (byte) uctoa::digit#2
|
||||
to:uctoa::@1
|
||||
uctoa::@5: scope:[uctoa] from uctoa::@2 uctoa::@7
|
||||
[176] (byte*) uctoa_append::buffer#0 ← (byte*) uctoa::buffer#11
|
||||
[177] (byte) uctoa_append::value#0 ← (byte) uctoa::value#2
|
||||
[178] (byte) uctoa_append::sub#0 ← (byte) uctoa::digit_value#0
|
||||
[179] call uctoa_append
|
||||
[180] (byte) uctoa_append::return#0 ← (byte) uctoa_append::value#2
|
||||
to:uctoa::@6
|
||||
uctoa::@6: scope:[uctoa] from uctoa::@5
|
||||
[181] (byte) uctoa::value#0 ← (byte) uctoa_append::return#0
|
||||
[182] (byte*) uctoa::buffer#4 ← ++ (byte*) uctoa::buffer#11
|
||||
to:uctoa::@4
|
||||
|
||||
(byte()) uctoa_append((byte*) uctoa_append::buffer , (byte) uctoa_append::value , (byte) uctoa_append::sub)
|
||||
uctoa_append: scope:[uctoa_append] from uctoa::@5
|
||||
[183] phi()
|
||||
to:uctoa_append::@1
|
||||
uctoa_append::@1: scope:[uctoa_append] from uctoa_append uctoa_append::@2
|
||||
[184] (byte) uctoa_append::digit#2 ← phi( uctoa_append/(byte) 0 uctoa_append::@2/(byte) uctoa_append::digit#1 )
|
||||
[184] (byte) uctoa_append::value#2 ← phi( uctoa_append/(byte) uctoa_append::value#0 uctoa_append::@2/(byte) uctoa_append::value#1 )
|
||||
[185] if((byte) uctoa_append::value#2>=(byte) uctoa_append::sub#0) goto uctoa_append::@2
|
||||
to:uctoa_append::@3
|
||||
uctoa_append::@3: scope:[uctoa_append] from uctoa_append::@1
|
||||
[186] *((byte*) uctoa_append::buffer#0) ← *((const byte*) DIGITS + (byte) uctoa_append::digit#2)
|
||||
to:uctoa_append::@return
|
||||
uctoa_append::@return: scope:[uctoa_append] from uctoa_append::@3
|
||||
[187] return
|
||||
to:@return
|
||||
uctoa_append::@2: scope:[uctoa_append] from uctoa_append::@1
|
||||
[188] (byte) uctoa_append::digit#1 ← ++ (byte) uctoa_append::digit#2
|
||||
[189] (byte) uctoa_append::value#1 ← (byte) uctoa_append::value#2 - (byte) uctoa_append::sub#0
|
||||
to:uctoa_append::@1
|
||||
|
||||
(void()) printf_uint((word) printf_uint::uvalue , (byte) printf_uint::format_min_length , (byte) printf_uint::format_justify_left , (byte) printf_uint::format_sign_always , (byte) printf_uint::format_zero_padding , (byte) printf_uint::format_upper_case , (byte) printf_uint::format_radix)
|
||||
printf_uint: scope:[printf_uint] from main::@2
|
||||
[190] phi()
|
||||
to:printf_uint::@1
|
||||
printf_uint::@1: scope:[printf_uint] from printf_uint
|
||||
[191] *((byte*)&(struct printf_buffer_number) printf_buffer) ← (byte) 0
|
||||
[192] (word) utoa::value#1 ← (word) printf_uint::uvalue#0
|
||||
[193] call utoa
|
||||
to:printf_uint::@2
|
||||
printf_uint::@2: scope:[printf_uint] from printf_uint::@1
|
||||
[194] (byte) printf_number_buffer::buffer_sign#0 ← *((byte*)&(struct printf_buffer_number) printf_buffer)
|
||||
[195] call printf_number_buffer
|
||||
to:printf_uint::@return
|
||||
printf_uint::@return: scope:[printf_uint] from printf_uint::@2
|
||||
[196] return
|
||||
to:@return
|
||||
|
||||
(void()) utoa((word) utoa::value , (byte*) utoa::buffer , (byte) utoa::radix)
|
||||
utoa: scope:[utoa] from printf_uint::@1
|
||||
[197] phi()
|
||||
to:utoa::@1
|
||||
utoa::@1: scope:[utoa] from utoa utoa::@4
|
||||
[198] (byte*) utoa::buffer#11 ← phi( utoa::@4/(byte*) utoa::buffer#14 utoa/(byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS )
|
||||
[198] (byte) utoa::started#2 ← phi( utoa::@4/(byte) utoa::started#4 utoa/(byte) 0 )
|
||||
[198] (word) utoa::value#2 ← phi( utoa::@4/(word) utoa::value#6 utoa/(word) utoa::value#1 )
|
||||
[198] (byte) utoa::digit#2 ← phi( utoa::@4/(byte) utoa::digit#1 utoa/(byte) 0 )
|
||||
[199] if((byte) utoa::digit#2<(const byte) utoa::max_digits#2-(byte) 1) goto utoa::@2
|
||||
to:utoa::@3
|
||||
utoa::@3: scope:[utoa] from utoa::@1
|
||||
[200] (byte~) utoa::$11 ← (byte)(word) utoa::value#2
|
||||
[201] *((byte*) utoa::buffer#11) ← *((const byte*) DIGITS + (byte~) utoa::$11)
|
||||
[202] (byte*) utoa::buffer#3 ← ++ (byte*) utoa::buffer#11
|
||||
[203] *((byte*) utoa::buffer#3) ← (byte) 0
|
||||
to:utoa::@return
|
||||
utoa::@return: scope:[utoa] from utoa::@3
|
||||
[204] return
|
||||
to:@return
|
||||
utoa::@2: scope:[utoa] from utoa::@1
|
||||
[205] (byte~) utoa::$10 ← (byte) utoa::digit#2 << (byte) 1
|
||||
[206] (word) utoa::digit_value#0 ← *((const word*) RADIX_HEXADECIMAL_VALUES + (byte~) utoa::$10)
|
||||
[207] if((byte) 0!=(byte) utoa::started#2) goto utoa::@5
|
||||
to:utoa::@7
|
||||
utoa::@7: scope:[utoa] from utoa::@2
|
||||
[208] if((word) utoa::value#2>=(word) utoa::digit_value#0) goto utoa::@5
|
||||
to:utoa::@4
|
||||
utoa::@4: scope:[utoa] from utoa::@6 utoa::@7
|
||||
[209] (byte*) utoa::buffer#14 ← phi( utoa::@7/(byte*) utoa::buffer#11 utoa::@6/(byte*) utoa::buffer#4 )
|
||||
[209] (byte) utoa::started#4 ← phi( utoa::@7/(byte) utoa::started#2 utoa::@6/(byte) 1 )
|
||||
[209] (word) utoa::value#6 ← phi( utoa::@7/(word) utoa::value#2 utoa::@6/(word) utoa::value#0 )
|
||||
[210] (byte) utoa::digit#1 ← ++ (byte) utoa::digit#2
|
||||
to:utoa::@1
|
||||
utoa::@5: scope:[utoa] from utoa::@2 utoa::@7
|
||||
[211] (byte*) utoa_append::buffer#0 ← (byte*) utoa::buffer#11
|
||||
[212] (word) utoa_append::value#0 ← (word) utoa::value#2
|
||||
[213] (word) utoa_append::sub#0 ← (word) utoa::digit_value#0
|
||||
[214] call utoa_append
|
||||
[215] (word) utoa_append::return#0 ← (word) utoa_append::value#2
|
||||
to:utoa::@6
|
||||
utoa::@6: scope:[utoa] from utoa::@5
|
||||
[216] (word) utoa::value#0 ← (word) utoa_append::return#0
|
||||
[217] (byte*) utoa::buffer#4 ← ++ (byte*) utoa::buffer#11
|
||||
to:utoa::@4
|
||||
|
||||
(word()) utoa_append((byte*) utoa_append::buffer , (word) utoa_append::value , (word) utoa_append::sub)
|
||||
utoa_append: scope:[utoa_append] from utoa::@5
|
||||
[218] phi()
|
||||
to:utoa_append::@1
|
||||
utoa_append::@1: scope:[utoa_append] from utoa_append utoa_append::@2
|
||||
[219] (byte) utoa_append::digit#2 ← phi( utoa_append/(byte) 0 utoa_append::@2/(byte) utoa_append::digit#1 )
|
||||
[219] (word) utoa_append::value#2 ← phi( utoa_append/(word) utoa_append::value#0 utoa_append::@2/(word) utoa_append::value#1 )
|
||||
[220] if((word) utoa_append::value#2>=(word) utoa_append::sub#0) goto utoa_append::@2
|
||||
to:utoa_append::@3
|
||||
utoa_append::@3: scope:[utoa_append] from utoa_append::@1
|
||||
[221] *((byte*) utoa_append::buffer#0) ← *((const byte*) DIGITS + (byte) utoa_append::digit#2)
|
||||
to:utoa_append::@return
|
||||
utoa_append::@return: scope:[utoa_append] from utoa_append::@3
|
||||
[222] return
|
||||
to:@return
|
||||
utoa_append::@2: scope:[utoa_append] from utoa_append::@1
|
||||
[223] (byte) utoa_append::digit#1 ← ++ (byte) utoa_append::digit#2
|
||||
[224] (word) utoa_append::value#1 ← (word) utoa_append::value#2 - (word) utoa_append::sub#0
|
||||
to:utoa_append::@1
|
||||
|
||||
(void()) clrscr()
|
||||
clrscr: scope:[clrscr] from main
|
||||
[225] phi()
|
||||
to:clrscr::@1
|
||||
clrscr::@1: scope:[clrscr] from clrscr clrscr::@5
|
||||
[226] (byte*) clrscr::line_cols#5 ← phi( clrscr/(const nomodify byte*) CONIO_SCREEN_COLORS clrscr::@5/(byte*) clrscr::line_cols#1 )
|
||||
[226] (byte*) clrscr::line_text#5 ← phi( clrscr/(const nomodify byte*) CONIO_SCREEN_TEXT clrscr::@5/(byte*) clrscr::line_text#1 )
|
||||
[226] (byte) clrscr::l#2 ← phi( clrscr/(byte) 0 clrscr::@5/(byte) clrscr::l#1 )
|
||||
[227] if((byte) clrscr::l#2<(byte) $19) goto clrscr::@3
|
||||
to:clrscr::@2
|
||||
clrscr::@2: scope:[clrscr] from clrscr::@1
|
||||
[228] (byte) conio_cursor_x ← (byte) 0
|
||||
[229] (byte) conio_cursor_y ← (byte) 0
|
||||
[230] (byte*) conio_cursor_text ← (const nomodify byte*) CONIO_SCREEN_TEXT
|
||||
[231] (byte*) conio_cursor_color ← (const nomodify byte*) CONIO_SCREEN_COLORS
|
||||
to:clrscr::@return
|
||||
clrscr::@return: scope:[clrscr] from clrscr::@2
|
||||
[232] return
|
||||
to:@return
|
||||
clrscr::@3: scope:[clrscr] from clrscr::@1 clrscr::@4
|
||||
[233] (byte) clrscr::c#2 ← phi( clrscr::@1/(byte) 0 clrscr::@4/(byte) clrscr::c#1 )
|
||||
[234] if((byte) clrscr::c#2<(byte) $28) goto clrscr::@4
|
||||
to:clrscr::@5
|
||||
clrscr::@5: scope:[clrscr] from clrscr::@3
|
||||
[235] (byte*) clrscr::line_text#1 ← (byte*) clrscr::line_text#5 + (byte) $28
|
||||
[236] (byte*) clrscr::line_cols#1 ← (byte*) clrscr::line_cols#5 + (byte) $28
|
||||
[237] (byte) clrscr::l#1 ← ++ (byte) clrscr::l#2
|
||||
to:clrscr::@1
|
||||
clrscr::@4: scope:[clrscr] from clrscr::@3
|
||||
[238] *((byte*) clrscr::line_text#5 + (byte) clrscr::c#2) ← (byte) ' '
|
||||
[239] *((byte*) clrscr::line_cols#5 + (byte) clrscr::c#2) ← (const nomodify byte) CONIO_TEXTCOLOR_DEFAULT
|
||||
[240] (byte) clrscr::c#1 ← ++ (byte) clrscr::c#2
|
||||
to:clrscr::@3
|
10357
src/test/ref/stars-1.log
Normal file
10357
src/test/ref/stars-1.log
Normal file
File diff suppressed because one or more lines are too long
413
src/test/ref/stars-1.sym
Normal file
413
src/test/ref/stars-1.sym
Normal file
@ -0,0 +1,413 @@
|
||||
(byte) $0::speed_x
|
||||
(byte) $0::speed_y
|
||||
(byte) $0::star_x
|
||||
(byte) $0::star_y
|
||||
(label) @1
|
||||
(label) @2
|
||||
(label) @begin
|
||||
(label) @end
|
||||
(const nomodify byte*) CONIO_SCREEN_COLORS = (byte*) 55296
|
||||
(const nomodify byte*) CONIO_SCREEN_TEXT = (byte*) 1024
|
||||
(const nomodify byte) CONIO_TEXTCOLOR_DEFAULT = (byte) $e
|
||||
(const byte*) DIGITS[] = (byte*) "0123456789abcdef"z
|
||||
(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS = (byte) 1
|
||||
(const byte) RADIX::BINARY = (number) 2
|
||||
(const byte) RADIX::DECIMAL = (number) $a
|
||||
(const byte) RADIX::HEXADECIMAL = (number) $10
|
||||
(const byte) RADIX::OCTAL = (number) 8
|
||||
(const byte*) RADIX_DECIMAL_VALUES_CHAR[] = { (byte) $64, (byte) $a }
|
||||
(const word*) RADIX_HEXADECIMAL_VALUES[] = { (word) $1000, (word) $100, (word) $10 }
|
||||
(const byte) SIZEOF_STRUCT_PRINTF_BUFFER_NUMBER = (byte) $c
|
||||
(void()) clrscr()
|
||||
(label) clrscr::@1
|
||||
(label) clrscr::@2
|
||||
(label) clrscr::@3
|
||||
(label) clrscr::@4
|
||||
(label) clrscr::@5
|
||||
(label) clrscr::@return
|
||||
(byte) clrscr::c
|
||||
(byte) clrscr::c#1 reg byte y 20002.0
|
||||
(byte) clrscr::c#2 reg byte y 12501.25
|
||||
(byte) clrscr::l
|
||||
(byte) clrscr::l#1 reg byte x 2002.0
|
||||
(byte) clrscr::l#2 reg byte x 333.6666666666667
|
||||
(byte*) clrscr::line_cols
|
||||
(byte*) clrscr::line_cols#1 line_cols zp[2]:16 1001.0
|
||||
(byte*) clrscr::line_cols#5 line_cols zp[2]:16 1500.375
|
||||
(byte*) clrscr::line_text
|
||||
(byte*) clrscr::line_text#1 line_text zp[2]:14 667.3333333333334
|
||||
(byte*) clrscr::line_text#5 line_text zp[2]:14 1714.7142857142858
|
||||
(byte*) conio_cursor_color loadstore zp[2]:22 1.8429752157024792E8
|
||||
(byte*) conio_cursor_text loadstore zp[2]:20 1.82786886147541E8
|
||||
(byte) conio_cursor_x loadstore zp[1]:18 3.1192661559633028E7
|
||||
(byte) conio_cursor_y loadstore zp[1]:19 2.5555555642857143E8
|
||||
(void()) cputc((byte) cputc::c)
|
||||
(label) cputc::@1
|
||||
(label) cputc::@2
|
||||
(label) cputc::@3
|
||||
(label) cputc::@return
|
||||
(byte) cputc::c
|
||||
(byte) cputc::c#0 reg byte a 2.0000002E7
|
||||
(byte) cputc::c#1 reg byte a 2.0000002E7
|
||||
(byte) cputc::c#2 reg byte a 20002.0
|
||||
(byte) cputc::c#3 reg byte a 1.100050025E8
|
||||
(void()) cputln()
|
||||
(byte*~) cputln::$0 zp[2]:20 2.000000002E9
|
||||
(byte*~) cputln::$1 zp[2]:20 2.000000002E9
|
||||
(byte*~) cputln::$2 zp[2]:22 2.000000002E9
|
||||
(byte*~) cputln::$3 zp[2]:22 2.000000002E9
|
||||
(label) cputln::@return
|
||||
(void()) cputs((to_nomodify byte*) cputs::s)
|
||||
(label) cputs::@1
|
||||
(label) cputs::@2
|
||||
(label) cputs::@return
|
||||
(byte) cputs::c
|
||||
(byte) cputs::c#1 reg byte a 1.0000001E7
|
||||
(to_nomodify byte*) cputs::s
|
||||
(to_nomodify byte*) cputs::s#0 s zp[2]:14 5000000.5
|
||||
(to_nomodify byte*) cputs::s#5 s zp[2]:14 1.5050002E7
|
||||
(to_nomodify byte*) cputs::s#6 s zp[2]:14 100001.0
|
||||
(void()) cscroll()
|
||||
(byte*~) cscroll::$7 zp[2]:20 2.0000000002E10
|
||||
(byte*~) cscroll::$8 zp[2]:22 2.0000000002E10
|
||||
(label) cscroll::@1
|
||||
(label) cscroll::@2
|
||||
(label) cscroll::@3
|
||||
(label) cscroll::@4
|
||||
(label) cscroll::@5
|
||||
(label) cscroll::@return
|
||||
(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::@8
|
||||
(label) main::@return
|
||||
(byte) main::i
|
||||
(byte) main::i#1 i zp[1]:2 202.0
|
||||
(byte) main::i#2 i zp[1]:2 20.2
|
||||
(struct $0*) main::pStar
|
||||
(struct $0*) main::pStar#1 pStar zp[2]:3 101.0
|
||||
(struct $0*) main::pStar#2 pStar zp[2]:3 14.428571428571429
|
||||
(const byte*) main::s[(byte) 2] = (byte*) " "
|
||||
(const byte*) main::s2[(byte) 2] = (byte*) "
|
||||
"
|
||||
(void*()) memcpy((void*) memcpy::destination , (void*) memcpy::source , (word) memcpy::num)
|
||||
(label) memcpy::@1
|
||||
(label) memcpy::@2
|
||||
(label) memcpy::@return
|
||||
(void*) memcpy::destination
|
||||
(void*) memcpy::destination#2 destination zp[2]:16
|
||||
(byte*) memcpy::dst
|
||||
(byte*) memcpy::dst#1 dst zp[2]:16 1.00000000000001E14
|
||||
(byte*) memcpy::dst#2 dst zp[2]:16 1.0003333333333467E14
|
||||
(byte*) memcpy::dst#4 dst zp[2]:16 2.00000000002E11
|
||||
(word) memcpy::num
|
||||
(void*) memcpy::return
|
||||
(void*) memcpy::source
|
||||
(void*) memcpy::source#2 source zp[2]:11
|
||||
(byte*) memcpy::src
|
||||
(byte*) memcpy::src#1 src zp[2]:11 2.00000000000002E14
|
||||
(byte*) memcpy::src#2 src zp[2]:11 1.0002500000000125E14
|
||||
(byte*) memcpy::src#4 src zp[2]:11 1.00000000001E11
|
||||
(byte*) memcpy::src_end
|
||||
(byte*) memcpy::src_end#0 src_end zp[2]:25 1.251250000000025E13
|
||||
(void*()) memset((void*) memset::str , (byte) memset::c , (word) memset::num)
|
||||
(label) memset::@1
|
||||
(label) memset::@2
|
||||
(label) memset::@3
|
||||
(label) memset::@return
|
||||
(byte) memset::c
|
||||
(byte) memset::c#4 reg byte x 1.4285714285714428E13
|
||||
(byte*) memset::dst
|
||||
(byte*) memset::dst#1 dst zp[2]:11 2.00000000000002E14
|
||||
(byte*) memset::dst#2 dst zp[2]:11 1.3336666666666834E14
|
||||
(byte*) memset::dst#4 dst zp[2]:11 2.00000000002E11
|
||||
(byte*) memset::end
|
||||
(byte*) memset::end#0 end zp[2]:25 1.6683333333333668E13
|
||||
(word) memset::num
|
||||
(void*) memset::return
|
||||
(void*) memset::str
|
||||
(void*) memset::str#3 str zp[2]:11
|
||||
(struct printf_buffer_number) printf_buffer loadstore mem[12] = {}
|
||||
(const byte*) printf_buffer_number::digits[(number) $b] = { fill( $b, 0) }
|
||||
(byte) printf_buffer_number::sign
|
||||
(byte) printf_format_number::justify_left
|
||||
(byte) printf_format_number::min_length
|
||||
(byte) printf_format_number::radix
|
||||
(byte) printf_format_number::sign_always
|
||||
(byte) printf_format_number::upper_case
|
||||
(byte) printf_format_number::zero_padding
|
||||
(byte) printf_format_string::justify_left
|
||||
(byte) printf_format_string::min_length
|
||||
(void()) printf_number_buffer((byte) printf_number_buffer::buffer_sign , (byte*) printf_number_buffer::buffer_digits , (byte) printf_number_buffer::format_min_length , (byte) printf_number_buffer::format_justify_left , (byte) printf_number_buffer::format_sign_always , (byte) printf_number_buffer::format_zero_padding , (byte) printf_number_buffer::format_upper_case , (byte) printf_number_buffer::format_radix)
|
||||
(word~) printf_number_buffer::$19 zp[2]:11 10001.0
|
||||
(label) printf_number_buffer::@1
|
||||
(label) printf_number_buffer::@10
|
||||
(label) printf_number_buffer::@11
|
||||
(label) printf_number_buffer::@12
|
||||
(label) printf_number_buffer::@13
|
||||
(label) printf_number_buffer::@14
|
||||
(label) printf_number_buffer::@15
|
||||
(label) printf_number_buffer::@16
|
||||
(label) printf_number_buffer::@17
|
||||
(label) printf_number_buffer::@18
|
||||
(label) printf_number_buffer::@19
|
||||
(label) printf_number_buffer::@2
|
||||
(label) printf_number_buffer::@20
|
||||
(label) printf_number_buffer::@21
|
||||
(label) printf_number_buffer::@3
|
||||
(label) printf_number_buffer::@4
|
||||
(label) printf_number_buffer::@5
|
||||
(label) printf_number_buffer::@6
|
||||
(label) printf_number_buffer::@7
|
||||
(label) printf_number_buffer::@8
|
||||
(label) printf_number_buffer::@9
|
||||
(label) printf_number_buffer::@return
|
||||
(struct printf_buffer_number) printf_number_buffer::buffer
|
||||
(byte*) printf_number_buffer::buffer_digits
|
||||
(byte) printf_number_buffer::buffer_sign
|
||||
(byte) printf_number_buffer::buffer_sign#0 buffer_sign zp[1]:13 2002.0
|
||||
(byte) printf_number_buffer::buffer_sign#1 buffer_sign zp[1]:13 2002.0
|
||||
(byte) printf_number_buffer::buffer_sign#10 buffer_sign zp[1]:13 1600.25
|
||||
(struct printf_format_number) printf_number_buffer::format
|
||||
(byte) printf_number_buffer::format_justify_left
|
||||
(byte) printf_number_buffer::format_justify_left#10 format_justify_left zp[1]:9 645.2258064516129
|
||||
(byte) printf_number_buffer::format_min_length
|
||||
(byte) printf_number_buffer::format_min_length#2 reg byte x 1000.1
|
||||
(byte) printf_number_buffer::format_radix
|
||||
(byte) printf_number_buffer::format_sign_always
|
||||
(byte) printf_number_buffer::format_upper_case
|
||||
(byte) printf_number_buffer::format_upper_case#10 format_upper_case zp[1]:24 384.65384615384613
|
||||
(byte) printf_number_buffer::format_zero_padding
|
||||
(byte) printf_number_buffer::format_zero_padding#10 format_zero_padding zp[1]:10 937.59375
|
||||
(signed byte) printf_number_buffer::len
|
||||
(signed byte) printf_number_buffer::len#0 reg byte y 15001.5
|
||||
(signed byte) printf_number_buffer::len#1 reg byte y 20002.0
|
||||
(signed byte) printf_number_buffer::len#2 reg byte y 30003.0
|
||||
(signed byte) printf_number_buffer::padding
|
||||
(signed byte) printf_number_buffer::padding#1 padding zp[1]:5 10001.0
|
||||
(signed byte) printf_number_buffer::padding#10 padding zp[1]:5 1904.952380952381
|
||||
(void()) printf_padding((byte) printf_padding::pad , (byte) printf_padding::length)
|
||||
(label) printf_padding::@1
|
||||
(label) printf_padding::@2
|
||||
(label) printf_padding::@3
|
||||
(label) printf_padding::@return
|
||||
(byte) printf_padding::i
|
||||
(byte) printf_padding::i#1 i zp[1]:8 2.0000002E7
|
||||
(byte) printf_padding::i#2 i zp[1]:8 7500000.75
|
||||
(byte) printf_padding::length
|
||||
(byte) printf_padding::length#0 length zp[1]:6 20002.0
|
||||
(byte) printf_padding::length#1 length zp[1]:6 20002.0
|
||||
(byte) printf_padding::length#2 length zp[1]:6 20002.0
|
||||
(byte) printf_padding::length#4 length zp[1]:6 1671667.3333333333
|
||||
(byte) printf_padding::pad
|
||||
(byte) printf_padding::pad#5 pad zp[1]:7 1666666.8333333333
|
||||
(void()) printf_uchar((byte) printf_uchar::uvalue , (byte) printf_uchar::format_min_length , (byte) printf_uchar::format_justify_left , (byte) printf_uchar::format_sign_always , (byte) printf_uchar::format_zero_padding , (byte) printf_uchar::format_upper_case , (byte) printf_uchar::format_radix)
|
||||
(label) printf_uchar::@1
|
||||
(label) printf_uchar::@2
|
||||
(label) printf_uchar::@return
|
||||
(struct printf_format_number) printf_uchar::format
|
||||
(byte) printf_uchar::format_justify_left
|
||||
(byte) printf_uchar::format_min_length
|
||||
(byte) printf_uchar::format_radix
|
||||
(byte) printf_uchar::format_sign_always
|
||||
(byte) printf_uchar::format_upper_case
|
||||
(byte) printf_uchar::format_zero_padding
|
||||
(byte) printf_uchar::uvalue
|
||||
(byte) printf_uchar::uvalue#0 reg byte x 202.0
|
||||
(byte) printf_uchar::uvalue#1 reg byte x 202.0
|
||||
(byte) printf_uchar::uvalue#2 reg byte x 601.5
|
||||
(void()) printf_uint((word) printf_uint::uvalue , (byte) printf_uint::format_min_length , (byte) printf_uint::format_justify_left , (byte) printf_uint::format_sign_always , (byte) printf_uint::format_zero_padding , (byte) printf_uint::format_upper_case , (byte) printf_uint::format_radix)
|
||||
(label) printf_uint::@1
|
||||
(label) printf_uint::@2
|
||||
(label) printf_uint::@return
|
||||
(struct printf_format_number) printf_uint::format
|
||||
(byte) printf_uint::format_justify_left
|
||||
(const byte) printf_uint::format_justify_left#0 format_justify_left = (byte) 0
|
||||
(byte) printf_uint::format_min_length
|
||||
(const byte) printf_uint::format_min_length#0 format_min_length = (byte) 0
|
||||
(byte) printf_uint::format_radix
|
||||
(byte) printf_uint::format_sign_always
|
||||
(byte) printf_uint::format_upper_case
|
||||
(const byte) printf_uint::format_upper_case#0 format_upper_case = (byte) 0
|
||||
(byte) printf_uint::format_zero_padding
|
||||
(const byte) printf_uint::format_zero_padding#0 format_zero_padding = (byte) 0
|
||||
(word) printf_uint::uvalue
|
||||
(word) printf_uint::uvalue#0 uvalue zp[2]:14 367.33333333333337
|
||||
(const struct $0*) stars[(number) 5] = { { star_x: (byte) $32, star_y: (byte) $32, speed_x: (byte) 2, speed_y: (byte) 7 }, { star_x: (byte) $28, star_y: (byte) $46, speed_x: (byte) 2, speed_y: (byte) 7 }, { star_x: (byte) $1e, star_y: (byte) $14, speed_x: (byte) 2, speed_y: (byte) 7 }, { star_x: (byte) $46, star_y: (byte) $a, speed_x: (byte) 2, speed_y: (byte) 7 }, { star_x: (byte) $28, star_y: (byte) $50, speed_x: (byte) 2, speed_y: (byte) 7 } }
|
||||
(word()) strlen((byte*) strlen::str)
|
||||
(label) strlen::@1
|
||||
(label) strlen::@2
|
||||
(label) strlen::@return
|
||||
(word) strlen::len
|
||||
(word) strlen::len#1 len zp[2]:11 1.0000001E7
|
||||
(word) strlen::len#2 len zp[2]:11 5002500.75
|
||||
(word) strlen::return
|
||||
(word) strlen::return#2 return zp[2]:11 20002.0
|
||||
(byte*) strlen::str
|
||||
(byte*) strlen::str#0 str zp[2]:16 2.0000002E7
|
||||
(byte*) strlen::str#2 str zp[2]:16 1.0000001E7
|
||||
(byte*()) strupr((byte*) strupr::str)
|
||||
(byte~) strupr::$0 reg byte a 2.0000002E7
|
||||
(label) strupr::@1
|
||||
(label) strupr::@2
|
||||
(label) strupr::@3
|
||||
(label) strupr::@return
|
||||
(byte*) strupr::return
|
||||
(byte*) strupr::src
|
||||
(byte*) strupr::src#1 src zp[2]:14 2.0000002E7
|
||||
(byte*) strupr::src#2 src zp[2]:14 7142857.857142856
|
||||
(byte*) strupr::str
|
||||
(const byte*) strupr::str#0 str = (byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
(byte()) toupper((byte) toupper::ch)
|
||||
(label) toupper::@1
|
||||
(label) toupper::@2
|
||||
(label) toupper::@return
|
||||
(byte) toupper::ch
|
||||
(byte) toupper::ch#0 reg byte a 1.70000002E8
|
||||
(byte) toupper::return
|
||||
(byte) toupper::return#0 reg byte a 2.00000002E8
|
||||
(byte) toupper::return#2 reg byte a 1.0333333466666667E8
|
||||
(byte) toupper::return#3 reg byte a 2.0000002E7
|
||||
(void()) uctoa((byte) uctoa::value , (byte*) uctoa::buffer , (byte) uctoa::radix)
|
||||
(label) uctoa::@1
|
||||
(label) uctoa::@2
|
||||
(label) uctoa::@3
|
||||
(label) uctoa::@4
|
||||
(label) uctoa::@5
|
||||
(label) uctoa::@6
|
||||
(label) uctoa::@7
|
||||
(label) uctoa::@return
|
||||
(byte*) uctoa::buffer
|
||||
(byte*) uctoa::buffer#11 buffer zp[2]:11 335000.50000000006
|
||||
(byte*) uctoa::buffer#14 buffer zp[2]:11 1500001.5
|
||||
(byte*) uctoa::buffer#3 buffer zp[2]:11 20002.0
|
||||
(byte*) uctoa::buffer#4 buffer zp[2]:11 2000002.0
|
||||
(byte) uctoa::digit
|
||||
(byte) uctoa::digit#1 digit zp[1]:9 2000002.0
|
||||
(byte) uctoa::digit#2 digit zp[1]:9 307692.6153846154
|
||||
(byte) uctoa::digit_value
|
||||
(byte) uctoa::digit_value#0 digit_value zp[1]:24 600000.6000000001
|
||||
(byte*) uctoa::digit_values
|
||||
(byte) uctoa::max_digits
|
||||
(byte) uctoa::radix
|
||||
(byte) uctoa::started
|
||||
(byte) uctoa::started#2 started zp[1]:10 600000.6000000001
|
||||
(byte) uctoa::started#4 started zp[1]:10 1000001.0
|
||||
(byte) uctoa::value
|
||||
(byte) uctoa::value#0 reg byte x 1000001.0
|
||||
(byte) uctoa::value#1 reg byte x 5501.0
|
||||
(byte) uctoa::value#2 reg byte x 670001.0000000001
|
||||
(byte) uctoa::value#6 reg byte x 1500001.5
|
||||
(byte()) uctoa_append((byte*) uctoa_append::buffer , (byte) uctoa_append::value , (byte) uctoa_append::sub)
|
||||
(label) uctoa_append::@1
|
||||
(label) uctoa_append::@2
|
||||
(label) uctoa_append::@3
|
||||
(label) uctoa_append::@return
|
||||
(byte*) uctoa_append::buffer
|
||||
(byte*) uctoa_append::buffer#0 buffer zp[2]:11 1375000.25
|
||||
(byte) uctoa_append::digit
|
||||
(byte) uctoa_append::digit#1 reg byte y 1.0000000001E10
|
||||
(byte) uctoa_append::digit#2 reg byte y 1.00050000015E10
|
||||
(byte) uctoa_append::return
|
||||
(byte) uctoa_append::return#0 reg byte x 2000002.0
|
||||
(byte) uctoa_append::sub
|
||||
(byte) uctoa_append::sub#0 sub zp[1]:24 3.3335000005E9
|
||||
(byte) uctoa_append::value
|
||||
(byte) uctoa_append::value#0 reg byte x 3666667.333333333
|
||||
(byte) uctoa_append::value#1 reg byte x 2.0000000002E10
|
||||
(byte) uctoa_append::value#2 reg byte x 5.001833334166666E9
|
||||
(void()) utoa((word) utoa::value , (byte*) utoa::buffer , (byte) utoa::radix)
|
||||
(byte~) utoa::$10 reg byte a 2000002.0
|
||||
(byte~) utoa::$11 reg byte a 20002.0
|
||||
(label) utoa::@1
|
||||
(label) utoa::@2
|
||||
(label) utoa::@3
|
||||
(label) utoa::@4
|
||||
(label) utoa::@5
|
||||
(label) utoa::@6
|
||||
(label) utoa::@7
|
||||
(label) utoa::@return
|
||||
(byte*) utoa::buffer
|
||||
(byte*) utoa::buffer#11 buffer zp[2]:16 287143.2857142857
|
||||
(byte*) utoa::buffer#14 buffer zp[2]:16 1500001.5
|
||||
(byte*) utoa::buffer#3 buffer zp[2]:16 20002.0
|
||||
(byte*) utoa::buffer#4 buffer zp[2]:16 2000002.0
|
||||
(byte) utoa::digit
|
||||
(byte) utoa::digit#1 digit zp[1]:13 2000002.0
|
||||
(byte) utoa::digit#2 digit zp[1]:13 285714.5714285714
|
||||
(word) utoa::digit_value
|
||||
(word) utoa::digit_value#0 digit_value zp[2]:25 600000.6000000001
|
||||
(word*) utoa::digit_values
|
||||
(byte) utoa::max_digits
|
||||
(const byte) utoa::max_digits#2 max_digits = (byte) 4
|
||||
(byte) utoa::radix
|
||||
(byte) utoa::started
|
||||
(byte) utoa::started#2 reg byte x 500000.5
|
||||
(byte) utoa::started#4 reg byte x 1000001.0
|
||||
(word) utoa::value
|
||||
(word) utoa::value#0 value zp[2]:14 1000001.0
|
||||
(word) utoa::value#1 value zp[2]:14 5501.0
|
||||
(word) utoa::value#2 value zp[2]:14 572857.857142857
|
||||
(word) utoa::value#6 value zp[2]:14 1500001.5
|
||||
(word()) utoa_append((byte*) utoa_append::buffer , (word) utoa_append::value , (word) utoa_append::sub)
|
||||
(label) utoa_append::@1
|
||||
(label) utoa_append::@2
|
||||
(label) utoa_append::@3
|
||||
(label) utoa_append::@return
|
||||
(byte*) utoa_append::buffer
|
||||
(byte*) utoa_append::buffer#0 buffer zp[2]:16 1375000.25
|
||||
(byte) utoa_append::digit
|
||||
(byte) utoa_append::digit#1 reg byte x 1.0000000001E10
|
||||
(byte) utoa_append::digit#2 reg byte x 1.00050000015E10
|
||||
(word) utoa_append::return
|
||||
(word) utoa_append::return#0 return zp[2]:14 2000002.0
|
||||
(word) utoa_append::sub
|
||||
(word) utoa_append::sub#0 sub zp[2]:25 3.3335000005E9
|
||||
(word) utoa_append::value
|
||||
(word) utoa_append::value#0 value zp[2]:14 3666667.333333333
|
||||
(word) utoa_append::value#1 value zp[2]:14 2.0000000002E10
|
||||
(word) utoa_append::value#2 value zp[2]:14 5.001833334166666E9
|
||||
|
||||
zp[1]:2 [ main::i#2 main::i#1 ]
|
||||
zp[2]:3 [ main::pStar#2 main::pStar#1 ]
|
||||
reg byte a [ cputc::c#3 cputc::c#0 cputc::c#2 cputc::c#1 ]
|
||||
reg byte x [ memset::c#4 ]
|
||||
reg byte x [ printf_uchar::uvalue#2 printf_uchar::uvalue#0 printf_uchar::uvalue#1 ]
|
||||
reg byte x [ printf_number_buffer::format_min_length#2 ]
|
||||
reg byte y [ printf_number_buffer::len#2 printf_number_buffer::len#0 printf_number_buffer::len#1 ]
|
||||
zp[1]:5 [ printf_number_buffer::padding#10 printf_number_buffer::padding#1 ]
|
||||
zp[1]:6 [ printf_padding::length#4 printf_padding::length#1 printf_padding::length#2 printf_padding::length#0 ]
|
||||
zp[1]:7 [ printf_padding::pad#5 ]
|
||||
zp[1]:8 [ printf_padding::i#2 printf_padding::i#1 ]
|
||||
reg byte a [ toupper::return#2 toupper::return#0 toupper::ch#0 ]
|
||||
zp[1]:9 [ uctoa::digit#2 uctoa::digit#1 printf_number_buffer::format_justify_left#10 ]
|
||||
reg byte x [ uctoa::value#2 uctoa::value#6 uctoa::value#1 uctoa::value#0 ]
|
||||
zp[1]:10 [ uctoa::started#2 uctoa::started#4 printf_number_buffer::format_zero_padding#10 ]
|
||||
zp[2]:11 [ uctoa::buffer#11 uctoa::buffer#14 uctoa::buffer#4 uctoa::buffer#3 uctoa_append::buffer#0 strlen::len#2 strlen::len#1 strlen::return#2 printf_number_buffer::$19 memcpy::source#2 memcpy::src#2 memcpy::src#4 memcpy::src#1 memset::str#3 memset::dst#2 memset::dst#4 memset::dst#1 ]
|
||||
reg byte x [ uctoa_append::value#2 uctoa_append::value#0 uctoa_append::value#1 ]
|
||||
reg byte y [ uctoa_append::digit#2 uctoa_append::digit#1 ]
|
||||
zp[1]:13 [ utoa::digit#2 utoa::digit#1 printf_number_buffer::buffer_sign#10 printf_number_buffer::buffer_sign#1 printf_number_buffer::buffer_sign#0 ]
|
||||
reg byte x [ utoa::started#2 utoa::started#4 ]
|
||||
reg byte x [ utoa_append::digit#2 utoa_append::digit#1 ]
|
||||
reg byte x [ clrscr::l#2 clrscr::l#1 ]
|
||||
zp[2]:14 [ clrscr::line_text#5 clrscr::line_text#1 utoa::value#2 utoa::value#6 utoa::value#1 utoa::value#0 utoa_append::value#2 utoa_append::value#0 utoa_append::value#1 printf_uint::uvalue#0 utoa_append::return#0 strupr::src#2 strupr::src#1 cputs::s#5 cputs::s#6 cputs::s#0 ]
|
||||
zp[2]:16 [ clrscr::line_cols#5 clrscr::line_cols#1 utoa::buffer#11 utoa::buffer#14 utoa::buffer#4 utoa::buffer#3 utoa_append::buffer#0 strlen::str#2 strlen::str#0 memcpy::destination#2 memcpy::dst#2 memcpy::dst#4 memcpy::dst#1 ]
|
||||
reg byte y [ clrscr::c#2 clrscr::c#1 ]
|
||||
zp[1]:18 [ conio_cursor_x ]
|
||||
zp[1]:19 [ conio_cursor_y ]
|
||||
zp[2]:20 [ conio_cursor_text cscroll::$7 cputln::$0 cputln::$1 ]
|
||||
zp[2]:22 [ conio_cursor_color cscroll::$8 cputln::$2 cputln::$3 ]
|
||||
reg byte a [ cputs::c#1 ]
|
||||
reg byte a [ toupper::return#3 ]
|
||||
reg byte a [ strupr::$0 ]
|
||||
zp[1]:24 [ uctoa::digit_value#0 uctoa_append::sub#0 printf_number_buffer::format_upper_case#10 ]
|
||||
reg byte x [ uctoa_append::return#0 ]
|
||||
reg byte a [ utoa::$11 ]
|
||||
reg byte a [ utoa::$10 ]
|
||||
zp[2]:25 [ utoa::digit_value#0 utoa_append::sub#0 memcpy::src_end#0 memset::end#0 ]
|
||||
mem[12] [ printf_buffer ]
|
558
src/test/ref/stars-2.asm
Normal file
558
src/test/ref/stars-2.asm
Normal file
@ -0,0 +1,558 @@
|
||||
// Stars struct of array
|
||||
.pc = $801 "Basic"
|
||||
:BasicUpstart(__bbegin)
|
||||
.pc = $80d "Program"
|
||||
// The default text color
|
||||
.const CONIO_TEXTCOLOR_DEFAULT = $e
|
||||
.const OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS = 1
|
||||
.const SIZEOF_STRUCT_PRINTF_BUFFER_NUMBER = $c
|
||||
// The screen width
|
||||
// The screen height
|
||||
// The screen bytes
|
||||
// The text screen address
|
||||
.label CONIO_SCREEN_TEXT = $400
|
||||
// The color screen address
|
||||
.label CONIO_SCREEN_COLORS = $d800
|
||||
.label conio_cursor_x = $b
|
||||
.label conio_cursor_y = $c
|
||||
.label conio_cursor_text = $d
|
||||
.label conio_cursor_color = $f
|
||||
__bbegin:
|
||||
// conio_cursor_x = 0
|
||||
// The current cursor x-position
|
||||
lda #0
|
||||
sta.z conio_cursor_x
|
||||
// conio_cursor_y = 0
|
||||
// The current cursor y-position
|
||||
sta.z conio_cursor_y
|
||||
// conio_cursor_text = CONIO_SCREEN_TEXT
|
||||
// The current cursor address
|
||||
lda #<CONIO_SCREEN_TEXT
|
||||
sta.z conio_cursor_text
|
||||
lda #>CONIO_SCREEN_TEXT
|
||||
sta.z conio_cursor_text+1
|
||||
// conio_cursor_color = CONIO_SCREEN_COLORS
|
||||
// The current cursor address
|
||||
lda #<CONIO_SCREEN_COLORS
|
||||
sta.z conio_cursor_color
|
||||
lda #>CONIO_SCREEN_COLORS
|
||||
sta.z conio_cursor_color+1
|
||||
jsr main
|
||||
rts
|
||||
main: {
|
||||
.label i = 2
|
||||
// clrscr()
|
||||
jsr clrscr
|
||||
lda #0
|
||||
sta.z i
|
||||
__b1:
|
||||
// for(char i=0;i<5;i++)
|
||||
lda.z i
|
||||
cmp #5
|
||||
bcc __b2
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// printf("%u %u\n", stars.star_x[i], stars.star_y[i])
|
||||
ldy.z i
|
||||
ldx stars,y
|
||||
jsr printf_uchar
|
||||
// printf("%u %u\n", stars.star_x[i], stars.star_y[i])
|
||||
lda #<s
|
||||
sta.z cputs.s
|
||||
lda #>s
|
||||
sta.z cputs.s+1
|
||||
jsr cputs
|
||||
// printf("%u %u\n", stars.star_x[i], stars.star_y[i])
|
||||
ldy.z i
|
||||
ldx stars+5,y
|
||||
jsr printf_uchar
|
||||
// printf("%u %u\n", stars.star_x[i], stars.star_y[i])
|
||||
lda #<s1
|
||||
sta.z cputs.s
|
||||
lda #>s1
|
||||
sta.z cputs.s+1
|
||||
jsr cputs
|
||||
// for(char i=0;i<5;i++)
|
||||
inc.z i
|
||||
jmp __b1
|
||||
s: .text " "
|
||||
.byte 0
|
||||
s1: .text @"\n"
|
||||
.byte 0
|
||||
}
|
||||
// Output a NUL-terminated string at the current cursor position
|
||||
// cputs(byte* zp(7) s)
|
||||
cputs: {
|
||||
.label s = 7
|
||||
__b1:
|
||||
// c=*s++
|
||||
ldy #0
|
||||
lda (s),y
|
||||
// while(c=*s++)
|
||||
inc.z s
|
||||
bne !+
|
||||
inc.z s+1
|
||||
!:
|
||||
cmp #0
|
||||
bne __b2
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// cputc(c)
|
||||
jsr cputc
|
||||
jmp __b1
|
||||
}
|
||||
// Output one character at the current cursor position
|
||||
// Moves the cursor forward. Scrolls the entire screen if needed
|
||||
// cputc(byte register(A) c)
|
||||
cputc: {
|
||||
// if(c=='\n')
|
||||
cmp #'\n'
|
||||
beq __b1
|
||||
// *conio_cursor_text++ = c
|
||||
ldy #0
|
||||
sta (conio_cursor_text),y
|
||||
// *conio_cursor_text++ = c;
|
||||
inc.z conio_cursor_text
|
||||
bne !+
|
||||
inc.z conio_cursor_text+1
|
||||
!:
|
||||
// *conio_cursor_color++ = conio_textcolor
|
||||
lda #CONIO_TEXTCOLOR_DEFAULT
|
||||
ldy #0
|
||||
sta (conio_cursor_color),y
|
||||
// *conio_cursor_color++ = conio_textcolor;
|
||||
inc.z conio_cursor_color
|
||||
bne !+
|
||||
inc.z conio_cursor_color+1
|
||||
!:
|
||||
// if(++conio_cursor_x==CONIO_WIDTH)
|
||||
inc.z conio_cursor_x
|
||||
lda #$28
|
||||
cmp.z conio_cursor_x
|
||||
bne __breturn
|
||||
// conio_cursor_x = 0
|
||||
lda #0
|
||||
sta.z conio_cursor_x
|
||||
// ++conio_cursor_y;
|
||||
inc.z conio_cursor_y
|
||||
// cscroll()
|
||||
jsr cscroll
|
||||
__breturn:
|
||||
// }
|
||||
rts
|
||||
__b1:
|
||||
// cputln()
|
||||
jsr cputln
|
||||
rts
|
||||
}
|
||||
// Print a newline
|
||||
cputln: {
|
||||
.label __0 = $d
|
||||
.label __1 = $d
|
||||
.label __2 = $f
|
||||
.label __3 = $f
|
||||
// conio_cursor_text - conio_cursor_x
|
||||
sec
|
||||
lda.z __0
|
||||
sbc.z conio_cursor_x
|
||||
sta.z __0
|
||||
bcs !+
|
||||
dec.z __0+1
|
||||
!:
|
||||
// conio_cursor_text - conio_cursor_x + CONIO_WIDTH
|
||||
lda #$28
|
||||
clc
|
||||
adc.z __1
|
||||
sta.z __1
|
||||
bcc !+
|
||||
inc.z __1+1
|
||||
!:
|
||||
// conio_cursor_text = conio_cursor_text - conio_cursor_x + CONIO_WIDTH
|
||||
// conio_cursor_color - conio_cursor_x
|
||||
sec
|
||||
lda.z __2
|
||||
sbc.z conio_cursor_x
|
||||
sta.z __2
|
||||
bcs !+
|
||||
dec.z __2+1
|
||||
!:
|
||||
// conio_cursor_color - conio_cursor_x + CONIO_WIDTH
|
||||
lda #$28
|
||||
clc
|
||||
adc.z __3
|
||||
sta.z __3
|
||||
bcc !+
|
||||
inc.z __3+1
|
||||
!:
|
||||
// conio_cursor_color = conio_cursor_color - conio_cursor_x + CONIO_WIDTH
|
||||
// conio_cursor_x = 0
|
||||
lda #0
|
||||
sta.z conio_cursor_x
|
||||
// conio_cursor_y++;
|
||||
inc.z conio_cursor_y
|
||||
// cscroll()
|
||||
jsr cscroll
|
||||
// }
|
||||
rts
|
||||
}
|
||||
// Scroll the entire screen if the cursor is beyond the last line
|
||||
cscroll: {
|
||||
.label __7 = $d
|
||||
.label __8 = $f
|
||||
// if(conio_cursor_y==CONIO_HEIGHT)
|
||||
lda #$19
|
||||
cmp.z conio_cursor_y
|
||||
bne __breturn
|
||||
// memcpy(CONIO_SCREEN_TEXT, CONIO_SCREEN_TEXT+CONIO_WIDTH, CONIO_BYTES-CONIO_WIDTH)
|
||||
lda #<CONIO_SCREEN_TEXT
|
||||
sta.z memcpy.destination
|
||||
lda #>CONIO_SCREEN_TEXT
|
||||
sta.z memcpy.destination+1
|
||||
lda #<CONIO_SCREEN_TEXT+$28
|
||||
sta.z memcpy.source
|
||||
lda #>CONIO_SCREEN_TEXT+$28
|
||||
sta.z memcpy.source+1
|
||||
jsr memcpy
|
||||
// memcpy(CONIO_SCREEN_COLORS, CONIO_SCREEN_COLORS+CONIO_WIDTH, CONIO_BYTES-CONIO_WIDTH)
|
||||
lda #<CONIO_SCREEN_COLORS
|
||||
sta.z memcpy.destination
|
||||
lda #>CONIO_SCREEN_COLORS
|
||||
sta.z memcpy.destination+1
|
||||
lda #<CONIO_SCREEN_COLORS+$28
|
||||
sta.z memcpy.source
|
||||
lda #>CONIO_SCREEN_COLORS+$28
|
||||
sta.z memcpy.source+1
|
||||
jsr memcpy
|
||||
// memset(CONIO_SCREEN_TEXT+CONIO_BYTES-CONIO_WIDTH, ' ', CONIO_WIDTH)
|
||||
ldx #' '
|
||||
lda #<CONIO_SCREEN_TEXT+$19*$28-$28
|
||||
sta.z memset.str
|
||||
lda #>CONIO_SCREEN_TEXT+$19*$28-$28
|
||||
sta.z memset.str+1
|
||||
jsr memset
|
||||
// memset(CONIO_SCREEN_COLORS+CONIO_BYTES-CONIO_WIDTH, conio_textcolor, CONIO_WIDTH)
|
||||
ldx #CONIO_TEXTCOLOR_DEFAULT
|
||||
lda #<CONIO_SCREEN_COLORS+$19*$28-$28
|
||||
sta.z memset.str
|
||||
lda #>CONIO_SCREEN_COLORS+$19*$28-$28
|
||||
sta.z memset.str+1
|
||||
jsr memset
|
||||
// conio_cursor_text-CONIO_WIDTH
|
||||
lda.z __7
|
||||
sec
|
||||
sbc #<$28
|
||||
sta.z __7
|
||||
lda.z __7+1
|
||||
sbc #>$28
|
||||
sta.z __7+1
|
||||
// conio_cursor_text = conio_cursor_text-CONIO_WIDTH
|
||||
// conio_cursor_color-CONIO_WIDTH
|
||||
lda.z __8
|
||||
sec
|
||||
sbc #<$28
|
||||
sta.z __8
|
||||
lda.z __8+1
|
||||
sbc #>$28
|
||||
sta.z __8+1
|
||||
// conio_cursor_color = conio_cursor_color-CONIO_WIDTH
|
||||
// conio_cursor_y--;
|
||||
dec.z conio_cursor_y
|
||||
__breturn:
|
||||
// }
|
||||
rts
|
||||
}
|
||||
// Copies the character c (an unsigned char) to the first num characters of the object pointed to by the argument str.
|
||||
// memset(void* zp(3) str, byte register(X) c)
|
||||
memset: {
|
||||
.label end = $11
|
||||
.label dst = 3
|
||||
.label str = 3
|
||||
// end = (char*)str + num
|
||||
lda #$28
|
||||
clc
|
||||
adc.z str
|
||||
sta.z end
|
||||
lda #0
|
||||
adc.z str+1
|
||||
sta.z end+1
|
||||
__b2:
|
||||
// for(char* dst = str; dst!=end; dst++)
|
||||
lda.z dst+1
|
||||
cmp.z end+1
|
||||
bne __b3
|
||||
lda.z dst
|
||||
cmp.z end
|
||||
bne __b3
|
||||
// }
|
||||
rts
|
||||
__b3:
|
||||
// *dst = c
|
||||
txa
|
||||
ldy #0
|
||||
sta (dst),y
|
||||
// for(char* dst = str; dst!=end; dst++)
|
||||
inc.z dst
|
||||
bne !+
|
||||
inc.z dst+1
|
||||
!:
|
||||
jmp __b2
|
||||
}
|
||||
// Copy block of memory (forwards)
|
||||
// Copies the values of num bytes from the location pointed to by source directly to the memory block pointed to by destination.
|
||||
// memcpy(void* zp(9) destination, void* zp(3) source)
|
||||
memcpy: {
|
||||
.label src_end = $11
|
||||
.label dst = 9
|
||||
.label src = 3
|
||||
.label source = 3
|
||||
.label destination = 9
|
||||
// src_end = (char*)source+num
|
||||
lda.z source
|
||||
clc
|
||||
adc #<$19*$28-$28
|
||||
sta.z src_end
|
||||
lda.z source+1
|
||||
adc #>$19*$28-$28
|
||||
sta.z src_end+1
|
||||
__b1:
|
||||
// while(src!=src_end)
|
||||
lda.z src+1
|
||||
cmp.z src_end+1
|
||||
bne __b2
|
||||
lda.z src
|
||||
cmp.z src_end
|
||||
bne __b2
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// *dst++ = *src++
|
||||
ldy #0
|
||||
lda (src),y
|
||||
sta (dst),y
|
||||
// *dst++ = *src++;
|
||||
inc.z dst
|
||||
bne !+
|
||||
inc.z dst+1
|
||||
!:
|
||||
inc.z src
|
||||
bne !+
|
||||
inc.z src+1
|
||||
!:
|
||||
jmp __b1
|
||||
}
|
||||
// Print an unsigned char using a specific format
|
||||
// printf_uchar(byte register(X) uvalue)
|
||||
printf_uchar: {
|
||||
// printf_buffer.sign = format.sign_always?'+':0
|
||||
// Handle any sign
|
||||
lda #0
|
||||
sta printf_buffer
|
||||
// uctoa(uvalue, printf_buffer.digits, format.radix)
|
||||
// Format number into buffer
|
||||
jsr uctoa
|
||||
// printf_number_buffer(printf_buffer, format)
|
||||
lda printf_buffer
|
||||
// Print using format
|
||||
jsr printf_number_buffer
|
||||
// }
|
||||
rts
|
||||
}
|
||||
// Print the contents of the number buffer using a specific format.
|
||||
// This handles minimum length, zero-filling, and left/right justification from the format
|
||||
// printf_number_buffer(byte register(A) buffer_sign)
|
||||
printf_number_buffer: {
|
||||
.label buffer_digits = printf_buffer+OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
// if(buffer.sign)
|
||||
cmp #0
|
||||
beq __b2
|
||||
// cputc(buffer.sign)
|
||||
jsr cputc
|
||||
__b2:
|
||||
// cputs(buffer.digits)
|
||||
lda #<buffer_digits
|
||||
sta.z cputs.s
|
||||
lda #>buffer_digits
|
||||
sta.z cputs.s+1
|
||||
jsr cputs
|
||||
// }
|
||||
rts
|
||||
}
|
||||
// Converts unsigned number value to a string representing it in RADIX format.
|
||||
// If the leading digits are zero they are not included in the string.
|
||||
// - value : The number to be converted to RADIX
|
||||
// - buffer : receives the string representing the number and zero-termination.
|
||||
// - radix : The radix to convert the number to (from the enum RADIX)
|
||||
// uctoa(byte register(X) value, byte* zp(7) buffer)
|
||||
uctoa: {
|
||||
.label digit_value = $13
|
||||
.label buffer = 7
|
||||
.label digit = 5
|
||||
.label started = 6
|
||||
lda #<printf_buffer+OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
sta.z buffer
|
||||
lda #>printf_buffer+OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
sta.z buffer+1
|
||||
lda #0
|
||||
sta.z started
|
||||
sta.z digit
|
||||
__b1:
|
||||
// for( char digit=0; digit<max_digits-1; digit++ )
|
||||
lda.z digit
|
||||
cmp #3-1
|
||||
bcc __b2
|
||||
// *buffer++ = DIGITS[(char)value]
|
||||
lda DIGITS,x
|
||||
ldy #0
|
||||
sta (buffer),y
|
||||
// *buffer++ = DIGITS[(char)value];
|
||||
inc.z buffer
|
||||
bne !+
|
||||
inc.z buffer+1
|
||||
!:
|
||||
// *buffer = 0
|
||||
lda #0
|
||||
tay
|
||||
sta (buffer),y
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// digit_value = digit_values[digit]
|
||||
ldy.z digit
|
||||
lda RADIX_DECIMAL_VALUES_CHAR,y
|
||||
sta.z digit_value
|
||||
// if (started || value >= digit_value)
|
||||
lda #0
|
||||
cmp.z started
|
||||
bne __b5
|
||||
cpx.z digit_value
|
||||
bcs __b5
|
||||
__b4:
|
||||
// for( char digit=0; digit<max_digits-1; digit++ )
|
||||
inc.z digit
|
||||
jmp __b1
|
||||
__b5:
|
||||
// uctoa_append(buffer++, value, digit_value)
|
||||
jsr uctoa_append
|
||||
// uctoa_append(buffer++, value, digit_value)
|
||||
// value = uctoa_append(buffer++, value, digit_value)
|
||||
// value = uctoa_append(buffer++, value, digit_value);
|
||||
inc.z buffer
|
||||
bne !+
|
||||
inc.z buffer+1
|
||||
!:
|
||||
lda #1
|
||||
sta.z started
|
||||
jmp __b4
|
||||
}
|
||||
// Used to convert a single digit of an unsigned number value to a string representation
|
||||
// Counts a single digit up from '0' as long as the value is larger than sub.
|
||||
// Each time the digit is increased sub is subtracted from value.
|
||||
// - buffer : pointer to the char that receives the digit
|
||||
// - value : The value where the digit will be derived from
|
||||
// - sub : the value of a '1' in the digit. Subtracted continually while the digit is increased.
|
||||
// (For decimal the subs used are 10000, 1000, 100, 10, 1)
|
||||
// returns : the value reduced by sub * digit so that it is less than sub.
|
||||
// uctoa_append(byte* zp(7) buffer, byte register(X) value, byte zp($13) sub)
|
||||
uctoa_append: {
|
||||
.label buffer = 7
|
||||
.label sub = $13
|
||||
ldy #0
|
||||
__b1:
|
||||
// while (value >= sub)
|
||||
cpx.z sub
|
||||
bcs __b2
|
||||
// *buffer = DIGITS[digit]
|
||||
lda DIGITS,y
|
||||
ldy #0
|
||||
sta (buffer),y
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
// digit++;
|
||||
iny
|
||||
// value -= sub
|
||||
txa
|
||||
sec
|
||||
sbc.z sub
|
||||
tax
|
||||
jmp __b1
|
||||
}
|
||||
// clears the screen and moves the cursor to the upper left-hand corner of the screen.
|
||||
clrscr: {
|
||||
.label line_text = 9
|
||||
.label line_cols = $d
|
||||
lda #<CONIO_SCREEN_COLORS
|
||||
sta.z line_cols
|
||||
lda #>CONIO_SCREEN_COLORS
|
||||
sta.z line_cols+1
|
||||
lda #<CONIO_SCREEN_TEXT
|
||||
sta.z line_text
|
||||
lda #>CONIO_SCREEN_TEXT
|
||||
sta.z line_text+1
|
||||
ldx #0
|
||||
__b1:
|
||||
// for( char l=0;l<CONIO_HEIGHT; l++ )
|
||||
cpx #$19
|
||||
bcc __b2
|
||||
// conio_cursor_x = 0
|
||||
lda #0
|
||||
sta.z conio_cursor_x
|
||||
// conio_cursor_y = 0
|
||||
sta.z conio_cursor_y
|
||||
// conio_cursor_text = CONIO_SCREEN_TEXT
|
||||
lda #<CONIO_SCREEN_TEXT
|
||||
sta.z conio_cursor_text
|
||||
lda #>CONIO_SCREEN_TEXT
|
||||
sta.z conio_cursor_text+1
|
||||
// conio_cursor_color = CONIO_SCREEN_COLORS
|
||||
lda #<CONIO_SCREEN_COLORS
|
||||
sta.z conio_cursor_color
|
||||
lda #>CONIO_SCREEN_COLORS
|
||||
sta.z conio_cursor_color+1
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
ldy #0
|
||||
__b3:
|
||||
// for( char c=0;c<CONIO_WIDTH; c++ )
|
||||
cpy #$28
|
||||
bcc __b4
|
||||
// line_text += CONIO_WIDTH
|
||||
lda #$28
|
||||
clc
|
||||
adc.z line_text
|
||||
sta.z line_text
|
||||
bcc !+
|
||||
inc.z line_text+1
|
||||
!:
|
||||
// line_cols += CONIO_WIDTH
|
||||
lda #$28
|
||||
clc
|
||||
adc.z line_cols
|
||||
sta.z line_cols
|
||||
bcc !+
|
||||
inc.z line_cols+1
|
||||
!:
|
||||
// for( char l=0;l<CONIO_HEIGHT; l++ )
|
||||
inx
|
||||
jmp __b1
|
||||
__b4:
|
||||
// line_text[c] = ' '
|
||||
lda #' '
|
||||
sta (line_text),y
|
||||
// line_cols[c] = conio_textcolor
|
||||
lda #CONIO_TEXTCOLOR_DEFAULT
|
||||
sta (line_cols),y
|
||||
// for( char c=0;c<CONIO_WIDTH; c++ )
|
||||
iny
|
||||
jmp __b3
|
||||
}
|
||||
// The digits used for numbers
|
||||
DIGITS: .text "0123456789abcdef"
|
||||
// Values of decimal digits
|
||||
RADIX_DECIMAL_VALUES_CHAR: .byte $64, $a
|
||||
// Buffer used for stringified number being printed
|
||||
printf_buffer: .fill SIZEOF_STRUCT_PRINTF_BUFFER_NUMBER, 0
|
||||
stars: .byte $32, $28, $1e, $46, $28, $32, $46, $14, $a, $50, 2, 2, 2, 2, 2, 7, 7, 7, 7, 7
|
316
src/test/ref/stars-2.cfg
Normal file
316
src/test/ref/stars-2.cfg
Normal file
@ -0,0 +1,316 @@
|
||||
@begin: scope:[] from
|
||||
[0] phi()
|
||||
to:@1
|
||||
@1: scope:[] from @begin
|
||||
[1] (byte) conio_cursor_x ← (byte) 0
|
||||
[2] (byte) conio_cursor_y ← (byte) 0
|
||||
[3] (byte*) conio_cursor_text ← (const nomodify byte*) CONIO_SCREEN_TEXT
|
||||
[4] (byte*) conio_cursor_color ← (const nomodify byte*) CONIO_SCREEN_COLORS
|
||||
to:@2
|
||||
@2: scope:[] from @1
|
||||
[5] phi()
|
||||
[6] call main
|
||||
to:@end
|
||||
@end: scope:[] from @2
|
||||
[7] phi()
|
||||
|
||||
(void()) main()
|
||||
main: scope:[main] from @2
|
||||
[8] phi()
|
||||
[9] call clrscr
|
||||
to:main::@1
|
||||
main::@1: scope:[main] from main main::@6
|
||||
[10] (byte) main::i#2 ← phi( main/(byte) 0 main::@6/(byte) main::i#1 )
|
||||
[11] if((byte) main::i#2<(byte) 5) goto main::@2
|
||||
to:main::@return
|
||||
main::@return: scope:[main] from main::@1
|
||||
[12] return
|
||||
to:@return
|
||||
main::@2: scope:[main] from main::@1
|
||||
[13] (byte) printf_uchar::uvalue#0 ← *((byte*)&(struct $0) stars + (byte) main::i#2)
|
||||
[14] call printf_uchar
|
||||
to:main::@3
|
||||
main::@3: scope:[main] from main::@2
|
||||
[15] phi()
|
||||
[16] call cputs
|
||||
to:main::@4
|
||||
main::@4: scope:[main] from main::@3
|
||||
[17] (byte) printf_uchar::uvalue#1 ← *((byte*)&(struct $0) stars+(byte) 5 + (byte) main::i#2)
|
||||
[18] call printf_uchar
|
||||
to:main::@5
|
||||
main::@5: scope:[main] from main::@4
|
||||
[19] phi()
|
||||
[20] call cputs
|
||||
to:main::@6
|
||||
main::@6: scope:[main] from main::@5
|
||||
[21] (byte) main::i#1 ← ++ (byte) main::i#2
|
||||
to:main::@1
|
||||
|
||||
(void()) cputs((to_nomodify byte*) cputs::s)
|
||||
cputs: scope:[cputs] from main::@3 main::@5 printf_number_buffer::@2
|
||||
[22] (to_nomodify byte*) cputs::s#5 ← phi( main::@3/(const byte*) main::s main::@5/(const byte*) main::s1 printf_number_buffer::@2/(const byte*) printf_number_buffer::buffer_digits#0 )
|
||||
to:cputs::@1
|
||||
cputs::@1: scope:[cputs] from cputs cputs::@2
|
||||
[23] (to_nomodify byte*) cputs::s#4 ← phi( cputs/(to_nomodify byte*) cputs::s#5 cputs::@2/(to_nomodify byte*) cputs::s#0 )
|
||||
[24] (byte) cputs::c#1 ← *((to_nomodify byte*) cputs::s#4)
|
||||
[25] (to_nomodify byte*) cputs::s#0 ← ++ (to_nomodify byte*) cputs::s#4
|
||||
[26] if((byte) 0!=(byte) cputs::c#1) goto cputs::@2
|
||||
to:cputs::@return
|
||||
cputs::@return: scope:[cputs] from cputs::@1
|
||||
[27] return
|
||||
to:@return
|
||||
cputs::@2: scope:[cputs] from cputs::@1
|
||||
[28] (byte) cputc::c#0 ← (byte) cputs::c#1
|
||||
[29] call cputc
|
||||
to:cputs::@1
|
||||
|
||||
(void()) cputc((byte) cputc::c)
|
||||
cputc: scope:[cputc] from cputs::@2 printf_number_buffer::@3
|
||||
[30] (byte) cputc::c#3 ← phi( cputs::@2/(byte) cputc::c#0 printf_number_buffer::@3/(byte) cputc::c#2 )
|
||||
[31] if((byte) cputc::c#3==(byte) '
|
||||
') goto cputc::@1
|
||||
to:cputc::@2
|
||||
cputc::@2: scope:[cputc] from cputc
|
||||
[32] *((byte*) conio_cursor_text) ← (byte) cputc::c#3
|
||||
[33] (byte*) conio_cursor_text ← ++ (byte*) conio_cursor_text
|
||||
[34] *((byte*) conio_cursor_color) ← (const nomodify byte) CONIO_TEXTCOLOR_DEFAULT
|
||||
[35] (byte*) conio_cursor_color ← ++ (byte*) conio_cursor_color
|
||||
[36] (byte) conio_cursor_x ← ++ (byte) conio_cursor_x
|
||||
[37] if((byte) conio_cursor_x!=(byte) $28) goto cputc::@return
|
||||
to:cputc::@3
|
||||
cputc::@3: scope:[cputc] from cputc::@2
|
||||
[38] (byte) conio_cursor_x ← (byte) 0
|
||||
[39] (byte) conio_cursor_y ← ++ (byte) conio_cursor_y
|
||||
[40] call cscroll
|
||||
to:cputc::@return
|
||||
cputc::@return: scope:[cputc] from cputc::@1 cputc::@2 cputc::@3
|
||||
[41] return
|
||||
to:@return
|
||||
cputc::@1: scope:[cputc] from cputc
|
||||
[42] phi()
|
||||
[43] call cputln
|
||||
to:cputc::@return
|
||||
|
||||
(void()) cputln()
|
||||
cputln: scope:[cputln] from cputc::@1
|
||||
[44] (byte*~) cputln::$0 ← (byte*) conio_cursor_text - (byte) conio_cursor_x
|
||||
[45] (byte*~) cputln::$1 ← (byte*~) cputln::$0 + (byte) $28
|
||||
[46] (byte*) conio_cursor_text ← (byte*~) cputln::$1
|
||||
[47] (byte*~) cputln::$2 ← (byte*) conio_cursor_color - (byte) conio_cursor_x
|
||||
[48] (byte*~) cputln::$3 ← (byte*~) cputln::$2 + (byte) $28
|
||||
[49] (byte*) conio_cursor_color ← (byte*~) cputln::$3
|
||||
[50] (byte) conio_cursor_x ← (byte) 0
|
||||
[51] (byte) conio_cursor_y ← ++ (byte) conio_cursor_y
|
||||
[52] call cscroll
|
||||
to:cputln::@return
|
||||
cputln::@return: scope:[cputln] from cputln
|
||||
[53] return
|
||||
to:@return
|
||||
|
||||
(void()) cscroll()
|
||||
cscroll: scope:[cscroll] from cputc::@3 cputln
|
||||
[54] if((byte) conio_cursor_y!=(byte) $19) goto cscroll::@return
|
||||
to:cscroll::@1
|
||||
cscroll::@1: scope:[cscroll] from cscroll
|
||||
[55] phi()
|
||||
[56] call memcpy
|
||||
to:cscroll::@2
|
||||
cscroll::@2: scope:[cscroll] from cscroll::@1
|
||||
[57] phi()
|
||||
[58] call memcpy
|
||||
to:cscroll::@3
|
||||
cscroll::@3: scope:[cscroll] from cscroll::@2
|
||||
[59] phi()
|
||||
[60] call memset
|
||||
to:cscroll::@4
|
||||
cscroll::@4: scope:[cscroll] from cscroll::@3
|
||||
[61] phi()
|
||||
[62] call memset
|
||||
to:cscroll::@5
|
||||
cscroll::@5: scope:[cscroll] from cscroll::@4
|
||||
[63] (byte*~) cscroll::$7 ← (byte*) conio_cursor_text - (byte) $28
|
||||
[64] (byte*) conio_cursor_text ← (byte*~) cscroll::$7
|
||||
[65] (byte*~) cscroll::$8 ← (byte*) conio_cursor_color - (byte) $28
|
||||
[66] (byte*) conio_cursor_color ← (byte*~) cscroll::$8
|
||||
[67] (byte) conio_cursor_y ← -- (byte) conio_cursor_y
|
||||
to:cscroll::@return
|
||||
cscroll::@return: scope:[cscroll] from cscroll cscroll::@5
|
||||
[68] return
|
||||
to:@return
|
||||
|
||||
(void*()) memset((void*) memset::str , (byte) memset::c , (word) memset::num)
|
||||
memset: scope:[memset] from cscroll::@3 cscroll::@4
|
||||
[69] (byte) memset::c#4 ← phi( cscroll::@3/(byte) ' ' cscroll::@4/(const nomodify byte) CONIO_TEXTCOLOR_DEFAULT )
|
||||
[69] (void*) memset::str#3 ← phi( cscroll::@3/(void*)(const nomodify byte*) CONIO_SCREEN_TEXT+(word)(number) $19*(number) $28-(byte) $28 cscroll::@4/(void*)(const nomodify byte*) CONIO_SCREEN_COLORS+(word)(number) $19*(number) $28-(byte) $28 )
|
||||
to:memset::@1
|
||||
memset::@1: scope:[memset] from memset
|
||||
[70] (byte*) memset::end#0 ← (byte*)(void*) memset::str#3 + (byte) $28
|
||||
[71] (byte*) memset::dst#4 ← (byte*)(void*) memset::str#3
|
||||
to:memset::@2
|
||||
memset::@2: scope:[memset] from memset::@1 memset::@3
|
||||
[72] (byte*) memset::dst#2 ← phi( memset::@1/(byte*) memset::dst#4 memset::@3/(byte*) memset::dst#1 )
|
||||
[73] if((byte*) memset::dst#2!=(byte*) memset::end#0) goto memset::@3
|
||||
to:memset::@return
|
||||
memset::@return: scope:[memset] from memset::@2
|
||||
[74] return
|
||||
to:@return
|
||||
memset::@3: scope:[memset] from memset::@2
|
||||
[75] *((byte*) memset::dst#2) ← (byte) memset::c#4
|
||||
[76] (byte*) memset::dst#1 ← ++ (byte*) memset::dst#2
|
||||
to:memset::@2
|
||||
|
||||
(void*()) memcpy((void*) memcpy::destination , (void*) memcpy::source , (word) memcpy::num)
|
||||
memcpy: scope:[memcpy] from cscroll::@1 cscroll::@2
|
||||
[77] (void*) memcpy::destination#2 ← phi( cscroll::@1/(void*)(const nomodify byte*) CONIO_SCREEN_TEXT cscroll::@2/(void*)(const nomodify byte*) CONIO_SCREEN_COLORS )
|
||||
[77] (void*) memcpy::source#2 ← phi( cscroll::@1/(void*)(const nomodify byte*) CONIO_SCREEN_TEXT+(byte) $28 cscroll::@2/(void*)(const nomodify byte*) CONIO_SCREEN_COLORS+(byte) $28 )
|
||||
[78] (byte*) memcpy::src_end#0 ← (byte*)(void*) memcpy::source#2 + (word)(number) $19*(number) $28-(number) $28
|
||||
[79] (byte*) memcpy::src#4 ← (byte*)(void*) memcpy::source#2
|
||||
[80] (byte*) memcpy::dst#4 ← (byte*)(void*) memcpy::destination#2
|
||||
to:memcpy::@1
|
||||
memcpy::@1: scope:[memcpy] from memcpy memcpy::@2
|
||||
[81] (byte*) memcpy::dst#2 ← phi( memcpy/(byte*) memcpy::dst#4 memcpy::@2/(byte*) memcpy::dst#1 )
|
||||
[81] (byte*) memcpy::src#2 ← phi( memcpy/(byte*) memcpy::src#4 memcpy::@2/(byte*) memcpy::src#1 )
|
||||
[82] if((byte*) memcpy::src#2!=(byte*) memcpy::src_end#0) goto memcpy::@2
|
||||
to:memcpy::@return
|
||||
memcpy::@return: scope:[memcpy] from memcpy::@1
|
||||
[83] return
|
||||
to:@return
|
||||
memcpy::@2: scope:[memcpy] from memcpy::@1
|
||||
[84] *((byte*) memcpy::dst#2) ← *((byte*) memcpy::src#2)
|
||||
[85] (byte*) memcpy::dst#1 ← ++ (byte*) memcpy::dst#2
|
||||
[86] (byte*) memcpy::src#1 ← ++ (byte*) memcpy::src#2
|
||||
to:memcpy::@1
|
||||
|
||||
(void()) printf_uchar((byte) printf_uchar::uvalue , (byte) printf_uchar::format_min_length , (byte) printf_uchar::format_justify_left , (byte) printf_uchar::format_sign_always , (byte) printf_uchar::format_zero_padding , (byte) printf_uchar::format_upper_case , (byte) printf_uchar::format_radix)
|
||||
printf_uchar: scope:[printf_uchar] from main::@2 main::@4
|
||||
[87] (byte) printf_uchar::uvalue#2 ← phi( main::@2/(byte) printf_uchar::uvalue#0 main::@4/(byte) printf_uchar::uvalue#1 )
|
||||
to:printf_uchar::@1
|
||||
printf_uchar::@1: scope:[printf_uchar] from printf_uchar
|
||||
[88] *((byte*)&(struct printf_buffer_number) printf_buffer) ← (byte) 0
|
||||
[89] (byte) uctoa::value#1 ← (byte) printf_uchar::uvalue#2
|
||||
[90] call uctoa
|
||||
to:printf_uchar::@2
|
||||
printf_uchar::@2: scope:[printf_uchar] from printf_uchar::@1
|
||||
[91] (byte) printf_number_buffer::buffer_sign#0 ← *((byte*)&(struct printf_buffer_number) printf_buffer)
|
||||
[92] call printf_number_buffer
|
||||
to:printf_uchar::@return
|
||||
printf_uchar::@return: scope:[printf_uchar] from printf_uchar::@2
|
||||
[93] return
|
||||
to:@return
|
||||
|
||||
(void()) printf_number_buffer((byte) printf_number_buffer::buffer_sign , (byte*) printf_number_buffer::buffer_digits , (byte) printf_number_buffer::format_min_length , (byte) printf_number_buffer::format_justify_left , (byte) printf_number_buffer::format_sign_always , (byte) printf_number_buffer::format_zero_padding , (byte) printf_number_buffer::format_upper_case , (byte) printf_number_buffer::format_radix)
|
||||
printf_number_buffer: scope:[printf_number_buffer] from printf_uchar::@2
|
||||
[94] phi()
|
||||
to:printf_number_buffer::@1
|
||||
printf_number_buffer::@1: scope:[printf_number_buffer] from printf_number_buffer
|
||||
[95] if((byte) 0==(byte) printf_number_buffer::buffer_sign#0) goto printf_number_buffer::@2
|
||||
to:printf_number_buffer::@3
|
||||
printf_number_buffer::@3: scope:[printf_number_buffer] from printf_number_buffer::@1
|
||||
[96] (byte) cputc::c#2 ← (byte) printf_number_buffer::buffer_sign#0
|
||||
[97] call cputc
|
||||
to:printf_number_buffer::@2
|
||||
printf_number_buffer::@2: scope:[printf_number_buffer] from printf_number_buffer::@1 printf_number_buffer::@3
|
||||
[98] phi()
|
||||
[99] call cputs
|
||||
to:printf_number_buffer::@return
|
||||
printf_number_buffer::@return: scope:[printf_number_buffer] from printf_number_buffer::@2
|
||||
[100] return
|
||||
to:@return
|
||||
|
||||
(void()) uctoa((byte) uctoa::value , (byte*) uctoa::buffer , (byte) uctoa::radix)
|
||||
uctoa: scope:[uctoa] from printf_uchar::@1
|
||||
[101] phi()
|
||||
to:uctoa::@1
|
||||
uctoa::@1: scope:[uctoa] from uctoa uctoa::@4
|
||||
[102] (byte*) uctoa::buffer#11 ← phi( uctoa::@4/(byte*) uctoa::buffer#14 uctoa/(byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS )
|
||||
[102] (byte) uctoa::started#2 ← phi( uctoa::@4/(byte) uctoa::started#4 uctoa/(byte) 0 )
|
||||
[102] (byte) uctoa::value#2 ← phi( uctoa::@4/(byte) uctoa::value#6 uctoa/(byte) uctoa::value#1 )
|
||||
[102] (byte) uctoa::digit#2 ← phi( uctoa::@4/(byte) uctoa::digit#1 uctoa/(byte) 0 )
|
||||
[103] if((byte) uctoa::digit#2<(byte) 3-(byte) 1) goto uctoa::@2
|
||||
to:uctoa::@3
|
||||
uctoa::@3: scope:[uctoa] from uctoa::@1
|
||||
[104] *((byte*) uctoa::buffer#11) ← *((const byte*) DIGITS + (byte) uctoa::value#2)
|
||||
[105] (byte*) uctoa::buffer#3 ← ++ (byte*) uctoa::buffer#11
|
||||
[106] *((byte*) uctoa::buffer#3) ← (byte) 0
|
||||
to:uctoa::@return
|
||||
uctoa::@return: scope:[uctoa] from uctoa::@3
|
||||
[107] return
|
||||
to:@return
|
||||
uctoa::@2: scope:[uctoa] from uctoa::@1
|
||||
[108] (byte) uctoa::digit_value#0 ← *((const byte*) RADIX_DECIMAL_VALUES_CHAR + (byte) uctoa::digit#2)
|
||||
[109] if((byte) 0!=(byte) uctoa::started#2) goto uctoa::@5
|
||||
to:uctoa::@7
|
||||
uctoa::@7: scope:[uctoa] from uctoa::@2
|
||||
[110] if((byte) uctoa::value#2>=(byte) uctoa::digit_value#0) goto uctoa::@5
|
||||
to:uctoa::@4
|
||||
uctoa::@4: scope:[uctoa] from uctoa::@6 uctoa::@7
|
||||
[111] (byte*) uctoa::buffer#14 ← phi( uctoa::@7/(byte*) uctoa::buffer#11 uctoa::@6/(byte*) uctoa::buffer#4 )
|
||||
[111] (byte) uctoa::started#4 ← phi( uctoa::@7/(byte) uctoa::started#2 uctoa::@6/(byte) 1 )
|
||||
[111] (byte) uctoa::value#6 ← phi( uctoa::@7/(byte) uctoa::value#2 uctoa::@6/(byte) uctoa::value#0 )
|
||||
[112] (byte) uctoa::digit#1 ← ++ (byte) uctoa::digit#2
|
||||
to:uctoa::@1
|
||||
uctoa::@5: scope:[uctoa] from uctoa::@2 uctoa::@7
|
||||
[113] (byte*) uctoa_append::buffer#0 ← (byte*) uctoa::buffer#11
|
||||
[114] (byte) uctoa_append::value#0 ← (byte) uctoa::value#2
|
||||
[115] (byte) uctoa_append::sub#0 ← (byte) uctoa::digit_value#0
|
||||
[116] call uctoa_append
|
||||
[117] (byte) uctoa_append::return#0 ← (byte) uctoa_append::value#2
|
||||
to:uctoa::@6
|
||||
uctoa::@6: scope:[uctoa] from uctoa::@5
|
||||
[118] (byte) uctoa::value#0 ← (byte) uctoa_append::return#0
|
||||
[119] (byte*) uctoa::buffer#4 ← ++ (byte*) uctoa::buffer#11
|
||||
to:uctoa::@4
|
||||
|
||||
(byte()) uctoa_append((byte*) uctoa_append::buffer , (byte) uctoa_append::value , (byte) uctoa_append::sub)
|
||||
uctoa_append: scope:[uctoa_append] from uctoa::@5
|
||||
[120] phi()
|
||||
to:uctoa_append::@1
|
||||
uctoa_append::@1: scope:[uctoa_append] from uctoa_append uctoa_append::@2
|
||||
[121] (byte) uctoa_append::digit#2 ← phi( uctoa_append/(byte) 0 uctoa_append::@2/(byte) uctoa_append::digit#1 )
|
||||
[121] (byte) uctoa_append::value#2 ← phi( uctoa_append/(byte) uctoa_append::value#0 uctoa_append::@2/(byte) uctoa_append::value#1 )
|
||||
[122] if((byte) uctoa_append::value#2>=(byte) uctoa_append::sub#0) goto uctoa_append::@2
|
||||
to:uctoa_append::@3
|
||||
uctoa_append::@3: scope:[uctoa_append] from uctoa_append::@1
|
||||
[123] *((byte*) uctoa_append::buffer#0) ← *((const byte*) DIGITS + (byte) uctoa_append::digit#2)
|
||||
to:uctoa_append::@return
|
||||
uctoa_append::@return: scope:[uctoa_append] from uctoa_append::@3
|
||||
[124] return
|
||||
to:@return
|
||||
uctoa_append::@2: scope:[uctoa_append] from uctoa_append::@1
|
||||
[125] (byte) uctoa_append::digit#1 ← ++ (byte) uctoa_append::digit#2
|
||||
[126] (byte) uctoa_append::value#1 ← (byte) uctoa_append::value#2 - (byte) uctoa_append::sub#0
|
||||
to:uctoa_append::@1
|
||||
|
||||
(void()) clrscr()
|
||||
clrscr: scope:[clrscr] from main
|
||||
[127] phi()
|
||||
to:clrscr::@1
|
||||
clrscr::@1: scope:[clrscr] from clrscr clrscr::@5
|
||||
[128] (byte*) clrscr::line_cols#5 ← phi( clrscr/(const nomodify byte*) CONIO_SCREEN_COLORS clrscr::@5/(byte*) clrscr::line_cols#1 )
|
||||
[128] (byte*) clrscr::line_text#5 ← phi( clrscr/(const nomodify byte*) CONIO_SCREEN_TEXT clrscr::@5/(byte*) clrscr::line_text#1 )
|
||||
[128] (byte) clrscr::l#2 ← phi( clrscr/(byte) 0 clrscr::@5/(byte) clrscr::l#1 )
|
||||
[129] if((byte) clrscr::l#2<(byte) $19) goto clrscr::@3
|
||||
to:clrscr::@2
|
||||
clrscr::@2: scope:[clrscr] from clrscr::@1
|
||||
[130] (byte) conio_cursor_x ← (byte) 0
|
||||
[131] (byte) conio_cursor_y ← (byte) 0
|
||||
[132] (byte*) conio_cursor_text ← (const nomodify byte*) CONIO_SCREEN_TEXT
|
||||
[133] (byte*) conio_cursor_color ← (const nomodify byte*) CONIO_SCREEN_COLORS
|
||||
to:clrscr::@return
|
||||
clrscr::@return: scope:[clrscr] from clrscr::@2
|
||||
[134] return
|
||||
to:@return
|
||||
clrscr::@3: scope:[clrscr] from clrscr::@1 clrscr::@4
|
||||
[135] (byte) clrscr::c#2 ← phi( clrscr::@1/(byte) 0 clrscr::@4/(byte) clrscr::c#1 )
|
||||
[136] if((byte) clrscr::c#2<(byte) $28) goto clrscr::@4
|
||||
to:clrscr::@5
|
||||
clrscr::@5: scope:[clrscr] from clrscr::@3
|
||||
[137] (byte*) clrscr::line_text#1 ← (byte*) clrscr::line_text#5 + (byte) $28
|
||||
[138] (byte*) clrscr::line_cols#1 ← (byte*) clrscr::line_cols#5 + (byte) $28
|
||||
[139] (byte) clrscr::l#1 ← ++ (byte) clrscr::l#2
|
||||
to:clrscr::@1
|
||||
clrscr::@4: scope:[clrscr] from clrscr::@3
|
||||
[140] *((byte*) clrscr::line_text#5 + (byte) clrscr::c#2) ← (byte) ' '
|
||||
[141] *((byte*) clrscr::line_cols#5 + (byte) clrscr::c#2) ← (const nomodify byte) CONIO_TEXTCOLOR_DEFAULT
|
||||
[142] (byte) clrscr::c#1 ← ++ (byte) clrscr::c#2
|
||||
to:clrscr::@3
|
6730
src/test/ref/stars-2.log
Normal file
6730
src/test/ref/stars-2.log
Normal file
File diff suppressed because one or more lines are too long
247
src/test/ref/stars-2.sym
Normal file
247
src/test/ref/stars-2.sym
Normal file
@ -0,0 +1,247 @@
|
||||
(const byte*) $0::speed_x[(number) 5] = { fill( 5, 0) }
|
||||
(const byte*) $0::speed_y[(number) 5] = { fill( 5, 0) }
|
||||
(const byte*) $0::star_x[(number) 5] = { fill( 5, 0) }
|
||||
(const byte*) $0::star_y[(number) 5] = { fill( 5, 0) }
|
||||
(label) @1
|
||||
(label) @2
|
||||
(label) @begin
|
||||
(label) @end
|
||||
(const nomodify byte*) CONIO_SCREEN_COLORS = (byte*) 55296
|
||||
(const nomodify byte*) CONIO_SCREEN_TEXT = (byte*) 1024
|
||||
(const nomodify byte) CONIO_TEXTCOLOR_DEFAULT = (byte) $e
|
||||
(const byte*) DIGITS[] = (byte*) "0123456789abcdef"z
|
||||
(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS = (byte) 1
|
||||
(const byte) RADIX::BINARY = (number) 2
|
||||
(const byte) RADIX::DECIMAL = (number) $a
|
||||
(const byte) RADIX::HEXADECIMAL = (number) $10
|
||||
(const byte) RADIX::OCTAL = (number) 8
|
||||
(const byte*) RADIX_DECIMAL_VALUES_CHAR[] = { (byte) $64, (byte) $a }
|
||||
(const byte) SIZEOF_STRUCT_PRINTF_BUFFER_NUMBER = (byte) $c
|
||||
(void()) clrscr()
|
||||
(label) clrscr::@1
|
||||
(label) clrscr::@2
|
||||
(label) clrscr::@3
|
||||
(label) clrscr::@4
|
||||
(label) clrscr::@5
|
||||
(label) clrscr::@return
|
||||
(byte) clrscr::c
|
||||
(byte) clrscr::c#1 reg byte y 20002.0
|
||||
(byte) clrscr::c#2 reg byte y 12501.25
|
||||
(byte) clrscr::l
|
||||
(byte) clrscr::l#1 reg byte x 2002.0
|
||||
(byte) clrscr::l#2 reg byte x 333.6666666666667
|
||||
(byte*) clrscr::line_cols
|
||||
(byte*) clrscr::line_cols#1 line_cols zp[2]:13 1001.0
|
||||
(byte*) clrscr::line_cols#5 line_cols zp[2]:13 1500.375
|
||||
(byte*) clrscr::line_text
|
||||
(byte*) clrscr::line_text#1 line_text zp[2]:9 667.3333333333334
|
||||
(byte*) clrscr::line_text#5 line_text zp[2]:9 1714.7142857142858
|
||||
(byte*) conio_cursor_color loadstore zp[2]:15 3.0972222375E8
|
||||
(byte*) conio_cursor_text loadstore zp[2]:13 3.054794535616439E8
|
||||
(byte) conio_cursor_x loadstore zp[1]:11 5.666666850000001E7
|
||||
(byte) conio_cursor_y loadstore zp[1]:12 4.1818181961038965E8
|
||||
(void()) cputc((byte) cputc::c)
|
||||
(label) cputc::@1
|
||||
(label) cputc::@2
|
||||
(label) cputc::@3
|
||||
(label) cputc::@return
|
||||
(byte) cputc::c
|
||||
(byte) cputc::c#0 reg byte a 2.0000002E7
|
||||
(byte) cputc::c#2 reg byte a 20002.0
|
||||
(byte) cputc::c#3 reg byte a 1.05005002E8
|
||||
(void()) cputln()
|
||||
(byte*~) cputln::$0 zp[2]:13 2.000000002E9
|
||||
(byte*~) cputln::$1 zp[2]:13 2.000000002E9
|
||||
(byte*~) cputln::$2 zp[2]:15 2.000000002E9
|
||||
(byte*~) cputln::$3 zp[2]:15 2.000000002E9
|
||||
(label) cputln::@return
|
||||
(void()) cputs((to_nomodify byte*) cputs::s)
|
||||
(label) cputs::@1
|
||||
(label) cputs::@2
|
||||
(label) cputs::@return
|
||||
(byte) cputs::c
|
||||
(byte) cputs::c#1 reg byte a 1.0000001E7
|
||||
(to_nomodify byte*) cputs::s
|
||||
(to_nomodify byte*) cputs::s#0 s zp[2]:7 5000000.5
|
||||
(to_nomodify byte*) cputs::s#4 s zp[2]:7 1.5050002E7
|
||||
(to_nomodify byte*) cputs::s#5 s zp[2]:7 100001.0
|
||||
(void()) cscroll()
|
||||
(byte*~) cscroll::$7 zp[2]:13 2.0000000002E10
|
||||
(byte*~) cscroll::$8 zp[2]:15 2.0000000002E10
|
||||
(label) cscroll::@1
|
||||
(label) cscroll::@2
|
||||
(label) cscroll::@3
|
||||
(label) cscroll::@4
|
||||
(label) cscroll::@5
|
||||
(label) cscroll::@return
|
||||
(void()) main()
|
||||
(label) main::@1
|
||||
(label) main::@2
|
||||
(label) main::@3
|
||||
(label) main::@4
|
||||
(label) main::@5
|
||||
(label) main::@6
|
||||
(label) main::@return
|
||||
(byte) main::i
|
||||
(byte) main::i#1 i zp[1]:2 202.0
|
||||
(byte) main::i#2 i zp[1]:2 50.5
|
||||
(const byte*) main::s[(byte) 2] = (byte*) " "
|
||||
(const byte*) main::s1[(byte) 2] = (byte*) "
|
||||
"
|
||||
(void*()) memcpy((void*) memcpy::destination , (void*) memcpy::source , (word) memcpy::num)
|
||||
(label) memcpy::@1
|
||||
(label) memcpy::@2
|
||||
(label) memcpy::@return
|
||||
(void*) memcpy::destination
|
||||
(void*) memcpy::destination#2 destination zp[2]:9
|
||||
(byte*) memcpy::dst
|
||||
(byte*) memcpy::dst#1 dst zp[2]:9 1.00000000000001E14
|
||||
(byte*) memcpy::dst#2 dst zp[2]:9 1.0003333333333467E14
|
||||
(byte*) memcpy::dst#4 dst zp[2]:9 2.00000000002E11
|
||||
(word) memcpy::num
|
||||
(void*) memcpy::return
|
||||
(void*) memcpy::source
|
||||
(void*) memcpy::source#2 source zp[2]:3
|
||||
(byte*) memcpy::src
|
||||
(byte*) memcpy::src#1 src zp[2]:3 2.00000000000002E14
|
||||
(byte*) memcpy::src#2 src zp[2]:3 1.0002500000000125E14
|
||||
(byte*) memcpy::src#4 src zp[2]:3 1.00000000001E11
|
||||
(byte*) memcpy::src_end
|
||||
(byte*) memcpy::src_end#0 src_end zp[2]:17 1.251250000000025E13
|
||||
(void*()) memset((void*) memset::str , (byte) memset::c , (word) memset::num)
|
||||
(label) memset::@1
|
||||
(label) memset::@2
|
||||
(label) memset::@3
|
||||
(label) memset::@return
|
||||
(byte) memset::c
|
||||
(byte) memset::c#4 reg byte x 1.4285714285714428E13
|
||||
(byte*) memset::dst
|
||||
(byte*) memset::dst#1 dst zp[2]:3 2.00000000000002E14
|
||||
(byte*) memset::dst#2 dst zp[2]:3 1.3336666666666834E14
|
||||
(byte*) memset::dst#4 dst zp[2]:3 2.00000000002E11
|
||||
(byte*) memset::end
|
||||
(byte*) memset::end#0 end zp[2]:17 1.6683333333333668E13
|
||||
(word) memset::num
|
||||
(void*) memset::return
|
||||
(void*) memset::str
|
||||
(void*) memset::str#3 str zp[2]:3
|
||||
(struct printf_buffer_number) printf_buffer loadstore mem[12] = {}
|
||||
(const byte*) printf_buffer_number::digits[(number) $b] = { fill( $b, 0) }
|
||||
(byte) printf_buffer_number::sign
|
||||
(byte) printf_format_number::justify_left
|
||||
(byte) printf_format_number::min_length
|
||||
(byte) printf_format_number::radix
|
||||
(byte) printf_format_number::sign_always
|
||||
(byte) printf_format_number::upper_case
|
||||
(byte) printf_format_number::zero_padding
|
||||
(byte) printf_format_string::justify_left
|
||||
(byte) printf_format_string::min_length
|
||||
(void()) printf_number_buffer((byte) printf_number_buffer::buffer_sign , (byte*) printf_number_buffer::buffer_digits , (byte) printf_number_buffer::format_min_length , (byte) printf_number_buffer::format_justify_left , (byte) printf_number_buffer::format_sign_always , (byte) printf_number_buffer::format_zero_padding , (byte) printf_number_buffer::format_upper_case , (byte) printf_number_buffer::format_radix)
|
||||
(label) printf_number_buffer::@1
|
||||
(label) printf_number_buffer::@2
|
||||
(label) printf_number_buffer::@3
|
||||
(label) printf_number_buffer::@return
|
||||
(struct printf_buffer_number) printf_number_buffer::buffer
|
||||
(byte*) printf_number_buffer::buffer_digits
|
||||
(const byte*) printf_number_buffer::buffer_digits#0 buffer_digits = (byte*)&(struct printf_buffer_number) printf_buffer+(const byte) OFFSET_STRUCT_PRINTF_BUFFER_NUMBER_DIGITS
|
||||
(byte) printf_number_buffer::buffer_sign
|
||||
(byte) printf_number_buffer::buffer_sign#0 reg byte a 7001.0
|
||||
(struct printf_format_number) printf_number_buffer::format
|
||||
(byte) printf_number_buffer::format_justify_left
|
||||
(byte) printf_number_buffer::format_min_length
|
||||
(byte) printf_number_buffer::format_radix
|
||||
(byte) printf_number_buffer::format_sign_always
|
||||
(byte) printf_number_buffer::format_upper_case
|
||||
(byte) printf_number_buffer::format_zero_padding
|
||||
(signed byte) printf_number_buffer::len
|
||||
(signed byte) printf_number_buffer::padding
|
||||
(void()) printf_uchar((byte) printf_uchar::uvalue , (byte) printf_uchar::format_min_length , (byte) printf_uchar::format_justify_left , (byte) printf_uchar::format_sign_always , (byte) printf_uchar::format_zero_padding , (byte) printf_uchar::format_upper_case , (byte) printf_uchar::format_radix)
|
||||
(label) printf_uchar::@1
|
||||
(label) printf_uchar::@2
|
||||
(label) printf_uchar::@return
|
||||
(struct printf_format_number) printf_uchar::format
|
||||
(byte) printf_uchar::format_justify_left
|
||||
(byte) printf_uchar::format_min_length
|
||||
(byte) printf_uchar::format_radix
|
||||
(byte) printf_uchar::format_sign_always
|
||||
(byte) printf_uchar::format_upper_case
|
||||
(byte) printf_uchar::format_zero_padding
|
||||
(byte) printf_uchar::uvalue
|
||||
(byte) printf_uchar::uvalue#0 reg byte x 202.0
|
||||
(byte) printf_uchar::uvalue#1 reg byte x 202.0
|
||||
(byte) printf_uchar::uvalue#2 reg byte x 601.5
|
||||
(struct $0) stars loadstore mem[20] = { star_x: { (byte) $32, (byte) $28, (byte) $1e, (byte) $46, (byte) $28 }, star_y: { (byte) $32, (byte) $46, (byte) $14, (byte) $a, (byte) $50 }, speed_x: { (byte) 2, (byte) 2, (byte) 2, (byte) 2, (byte) 2 }, speed_y: { (byte) 7, (byte) 7, (byte) 7, (byte) 7, (byte) 7 } }
|
||||
(void()) uctoa((byte) uctoa::value , (byte*) uctoa::buffer , (byte) uctoa::radix)
|
||||
(label) uctoa::@1
|
||||
(label) uctoa::@2
|
||||
(label) uctoa::@3
|
||||
(label) uctoa::@4
|
||||
(label) uctoa::@5
|
||||
(label) uctoa::@6
|
||||
(label) uctoa::@7
|
||||
(label) uctoa::@return
|
||||
(byte*) uctoa::buffer
|
||||
(byte*) uctoa::buffer#11 buffer zp[2]:7 335000.50000000006
|
||||
(byte*) uctoa::buffer#14 buffer zp[2]:7 1500001.5
|
||||
(byte*) uctoa::buffer#3 buffer zp[2]:7 20002.0
|
||||
(byte*) uctoa::buffer#4 buffer zp[2]:7 2000002.0
|
||||
(byte) uctoa::digit
|
||||
(byte) uctoa::digit#1 digit zp[1]:5 2000002.0
|
||||
(byte) uctoa::digit#2 digit zp[1]:5 307692.6153846154
|
||||
(byte) uctoa::digit_value
|
||||
(byte) uctoa::digit_value#0 digit_value zp[1]:19 600000.6000000001
|
||||
(byte*) uctoa::digit_values
|
||||
(byte) uctoa::max_digits
|
||||
(byte) uctoa::radix
|
||||
(byte) uctoa::started
|
||||
(byte) uctoa::started#2 started zp[1]:6 600000.6000000001
|
||||
(byte) uctoa::started#4 started zp[1]:6 1000001.0
|
||||
(byte) uctoa::value
|
||||
(byte) uctoa::value#0 reg byte x 1000001.0
|
||||
(byte) uctoa::value#1 reg byte x 5501.0
|
||||
(byte) uctoa::value#2 reg byte x 670001.0000000001
|
||||
(byte) uctoa::value#6 reg byte x 1500001.5
|
||||
(byte()) uctoa_append((byte*) uctoa_append::buffer , (byte) uctoa_append::value , (byte) uctoa_append::sub)
|
||||
(label) uctoa_append::@1
|
||||
(label) uctoa_append::@2
|
||||
(label) uctoa_append::@3
|
||||
(label) uctoa_append::@return
|
||||
(byte*) uctoa_append::buffer
|
||||
(byte*) uctoa_append::buffer#0 buffer zp[2]:7 1375000.25
|
||||
(byte) uctoa_append::digit
|
||||
(byte) uctoa_append::digit#1 reg byte y 1.0000000001E10
|
||||
(byte) uctoa_append::digit#2 reg byte y 1.00050000015E10
|
||||
(byte) uctoa_append::return
|
||||
(byte) uctoa_append::return#0 reg byte x 2000002.0
|
||||
(byte) uctoa_append::sub
|
||||
(byte) uctoa_append::sub#0 sub zp[1]:19 3.3335000005E9
|
||||
(byte) uctoa_append::value
|
||||
(byte) uctoa_append::value#0 reg byte x 3666667.333333333
|
||||
(byte) uctoa_append::value#1 reg byte x 2.0000000002E10
|
||||
(byte) uctoa_append::value#2 reg byte x 5.001833334166666E9
|
||||
|
||||
zp[1]:2 [ main::i#2 main::i#1 ]
|
||||
reg byte a [ cputc::c#3 cputc::c#0 cputc::c#2 ]
|
||||
reg byte x [ memset::c#4 ]
|
||||
zp[2]:3 [ memcpy::source#2 memcpy::src#2 memcpy::src#4 memcpy::src#1 memset::str#3 memset::dst#2 memset::dst#4 memset::dst#1 ]
|
||||
reg byte x [ printf_uchar::uvalue#2 printf_uchar::uvalue#0 printf_uchar::uvalue#1 ]
|
||||
zp[1]:5 [ uctoa::digit#2 uctoa::digit#1 ]
|
||||
reg byte x [ uctoa::value#2 uctoa::value#6 uctoa::value#1 uctoa::value#0 ]
|
||||
zp[1]:6 [ uctoa::started#2 uctoa::started#4 ]
|
||||
zp[2]:7 [ uctoa::buffer#11 uctoa::buffer#14 uctoa::buffer#4 uctoa::buffer#3 uctoa_append::buffer#0 cputs::s#4 cputs::s#5 cputs::s#0 ]
|
||||
reg byte x [ uctoa_append::value#2 uctoa_append::value#0 uctoa_append::value#1 ]
|
||||
reg byte y [ uctoa_append::digit#2 uctoa_append::digit#1 ]
|
||||
reg byte x [ clrscr::l#2 clrscr::l#1 ]
|
||||
zp[2]:9 [ clrscr::line_text#5 clrscr::line_text#1 memcpy::destination#2 memcpy::dst#2 memcpy::dst#4 memcpy::dst#1 ]
|
||||
reg byte y [ clrscr::c#2 clrscr::c#1 ]
|
||||
zp[1]:11 [ conio_cursor_x ]
|
||||
zp[1]:12 [ conio_cursor_y ]
|
||||
zp[2]:13 [ conio_cursor_text cscroll::$7 cputln::$0 cputln::$1 clrscr::line_cols#5 clrscr::line_cols#1 ]
|
||||
zp[2]:15 [ conio_cursor_color cscroll::$8 cputln::$2 cputln::$3 ]
|
||||
reg byte a [ cputs::c#1 ]
|
||||
zp[2]:17 [ memcpy::src_end#0 memset::end#0 ]
|
||||
reg byte a [ printf_number_buffer::buffer_sign#0 ]
|
||||
zp[1]:19 [ uctoa::digit_value#0 uctoa_append::sub#0 ]
|
||||
reg byte x [ uctoa_append::return#0 ]
|
||||
mem[12] [ printf_buffer ]
|
||||
mem[20] [ stars ]
|
Loading…
Reference in New Issue
Block a user