mirror of
https://gitlab.com/camelot/kickc.git
synced 2025-02-16 18:30:37 +00:00
Updated const names to VICII.
This commit is contained in:
parent
581f055561
commit
2dd2697ba1
@ -142,7 +142,7 @@ const char BORDER_YPOS_TOP=50;
|
||||
const char BORDER_YPOS_BOTTOM=250;
|
||||
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
const unsigned int SPRITE_PTRS = $3f8;
|
||||
const unsigned int OFFSET_SPRITE_PTRS = 0x3f8;
|
||||
|
||||
char * const SPRITES_XPOS = $d000;
|
||||
char * const SPRITES_YPOS = $d001;
|
||||
|
@ -183,7 +183,7 @@ void processChars() {
|
||||
// Set the sprite color
|
||||
SPRITES_COLOR[processing->id] = processing->col;
|
||||
// Set sprite pointer
|
||||
*(SCREEN+SPRITE_PTRS+processing->id) = processing->ptr;
|
||||
*(SCREEN+OFFSET_SPRITE_PTRS+processing->id) = processing->ptr;
|
||||
// Set status
|
||||
processing->status = STATUS_PROCESSING;
|
||||
}
|
||||
|
@ -7,7 +7,7 @@ char * const SPRITES = 0x3000;
|
||||
char * const SCREEN = 0x0400;
|
||||
|
||||
// Address of sprite pointers on screen
|
||||
char * const SCREEN_SPRITES = SCREEN + SPRITE_PTRS;
|
||||
char * const SCREEN_SPRITES = SCREEN + OFFSET_SPRITE_PTRS;
|
||||
|
||||
// Sprite pointer for sprite 0
|
||||
char SPRITE_0 = toSpritePtr(SPRITES);
|
||||
|
@ -6,9 +6,9 @@ char* const PLAYFIELD_SCREEN_1 = 0x0400;
|
||||
// Address of the second screen
|
||||
char* const PLAYFIELD_SCREEN_2 = 0x2c00;
|
||||
// Screen Sprite pointers on screen 1
|
||||
char* const PLAYFIELD_SPRITE_PTRS_1 = (PLAYFIELD_SCREEN_1+SPRITE_PTRS);
|
||||
char* const PLAYFIELD_SPRITE_PTRS_1 = (PLAYFIELD_SCREEN_1+OFFSET_SPRITE_PTRS);
|
||||
// Screen Sprite pointers on screen 2
|
||||
char* const PLAYFIELD_SPRITE_PTRS_2 = (PLAYFIELD_SCREEN_2+SPRITE_PTRS);
|
||||
char* const PLAYFIELD_SPRITE_PTRS_2 = (PLAYFIELD_SCREEN_2+OFFSET_SPRITE_PTRS);
|
||||
|
||||
// Sprites covering the playfield
|
||||
__address(0x3000) char PLAYFIELD_SPRITES[30*64] = kickasm(resource "playfield-sprites.png") {{
|
||||
|
@ -23,7 +23,7 @@ export char SPRITE[] = kickasm(resource "sprite.png") {{
|
||||
char* const LOAD_SPRITE = 0x3000;
|
||||
|
||||
char* const SCREEN = 0x0400;
|
||||
char* const SPRITES_PTR = SCREEN+SPRITE_PTRS;
|
||||
char* const SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS;
|
||||
|
||||
void main() {
|
||||
// Load sprite file into memory
|
||||
|
@ -25,7 +25,7 @@ export __address(0x2040) char SPRITE[0x40] = kickasm(resource "sprite.png") {{
|
||||
#pragma data_seg(Data)
|
||||
|
||||
char* const SCREEN = 0x0400;
|
||||
char* const SPRITES_PTR = SCREEN+SPRITE_PTRS;
|
||||
char* const SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS;
|
||||
|
||||
void main() {
|
||||
// Install the Krill drive code
|
||||
|
@ -5,7 +5,7 @@
|
||||
|
||||
char* const SCREEN = 0x0400;
|
||||
char* const SPRITE = 0x2000;
|
||||
char* const SPRITES = SCREEN+SPRITE_PTRS;
|
||||
char* const SPRITES = SCREEN+OFFSET_SPRITE_PTRS;
|
||||
|
||||
void* const GENERATOR = 0x0900;
|
||||
|
||||
|
@ -24,7 +24,7 @@ void main() {
|
||||
*SPRITES_ENABLE = 1;
|
||||
SPRITES_YPOS[0] = 100;
|
||||
SPRITES_XPOS[0] = 100;
|
||||
*(SCREEN+SPRITE_PTRS) = (byte)(SPRITE/0x40);
|
||||
*(SCREEN+OFFSET_SPRITE_PTRS) = (byte)(SPRITE/0x40);
|
||||
|
||||
saveZeropage();
|
||||
sinZeropage();
|
||||
|
@ -21,7 +21,7 @@
|
||||
.const BORDER_YPOS_TOP = $32
|
||||
.const BORDER_YPOS_BOTTOM = $fa
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
// Bits for the VICII IRQ Status/Enable Registers
|
||||
.const IRQ_RASTER = 1
|
||||
// Mask for PROCESSOR_PORT_DDR which allows only memory configuration to be written
|
||||
@ -369,7 +369,7 @@ processChars: {
|
||||
tay
|
||||
pla
|
||||
sta SPRITES_COLOR,y
|
||||
// *(SCREEN+SPRITE_PTRS+processing->id) = processing->ptr
|
||||
// *(SCREEN+OFFSET_SPRITE_PTRS+processing->id) = processing->ptr
|
||||
// Set sprite pointer
|
||||
ldy #OFFSET_STRUCT_PROCESSINGSPRITE_PTR
|
||||
lda (processing),y
|
||||
@ -378,7 +378,7 @@ processChars: {
|
||||
lda (processing),y
|
||||
tay
|
||||
pla
|
||||
sta SCREEN+SPRITE_PTRS,y
|
||||
sta SCREEN+OFFSET_SPRITE_PTRS,y
|
||||
// processing->status = STATUS_PROCESSING
|
||||
// Set status
|
||||
lda #STATUS_PROCESSING
|
||||
|
@ -147,7 +147,7 @@ processChars::@11: scope:[processChars] from processChars::@10
|
||||
[71] *(((byte**)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_SCREENPTR]) = ' '
|
||||
[72] *SPRITES_ENABLE = *SPRITES_ENABLE | processChars::bitmask#0
|
||||
[73] SPRITES_COLOR[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_COL]
|
||||
[74] (SCREEN+SPRITE_PTRS)[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_PTR]
|
||||
[74] (SCREEN+OFFSET_SPRITE_PTRS)[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_PTR]
|
||||
[75] ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_STATUS] = STATUS_PROCESSING
|
||||
to:processChars::@3
|
||||
processChars::@3: scope:[processChars] from processChars::@10 processChars::@11
|
||||
|
@ -670,7 +670,7 @@ processChars::@11: scope:[processChars] from processChars::@10
|
||||
SPRITES_COLOR[*processChars::$37] = *processChars::$36
|
||||
processChars::$64 = (byte*)processChars::processing#3
|
||||
processChars::$38 = processChars::$64 + OFFSET_STRUCT_PROCESSINGSPRITE_ID
|
||||
processChars::$7 = SCREEN+SPRITE_PTRS + *processChars::$38
|
||||
processChars::$7 = SCREEN+OFFSET_SPRITE_PTRS + *processChars::$38
|
||||
processChars::$65 = (byte*)processChars::processing#3
|
||||
processChars::$39 = processChars::$65 + OFFSET_STRUCT_PROCESSINGSPRITE_PTR
|
||||
*processChars::$7 = *processChars::$39
|
||||
@ -1091,6 +1091,7 @@ const nomodify byte* IRQ_STATUS = (byte*)$d019
|
||||
const nomodify byte LIGHT_BLUE = $e
|
||||
const nomodify byte NOT_FOUND = $ff
|
||||
const nomodify byte NUM_PROCESSING = 8
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_INTERRUPT = $d
|
||||
const byte OFFSET_STRUCT_PROCESSINGSPRITE_COL = $a
|
||||
const byte OFFSET_STRUCT_PROCESSINGSPRITE_ID = 8
|
||||
@ -1175,7 +1176,6 @@ const nomodify byte* SPRITES_XMSB = (byte*)$d010
|
||||
const nomodify byte* SPRITES_XPOS = (byte*)$d000
|
||||
const nomodify byte* SPRITES_YPOS = (byte*)$d001
|
||||
const nomodify byte* SPRITE_DATA = (byte*)$2000
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const byte STATUS_FREE = 0
|
||||
const byte STATUS_NEW = 1
|
||||
const byte STATUS_PROCESSING = 2
|
||||
@ -2568,9 +2568,9 @@ Converting *(pointer+n) to pointer[n] [212] processChars::xpos#0 = *processChars
|
||||
Converting *(pointer+n) to pointer[n] [218] *(*processChars::$35) = ' ' -- processChars::$61[OFFSET_STRUCT_PROCESSINGSPRITE_SCREENPTR]
|
||||
Converting *(pointer+n) to pointer[n] [224] SPRITES_COLOR[*processChars::$37] = *processChars::$36 -- processChars::$62[OFFSET_STRUCT_PROCESSINGSPRITE_COL]
|
||||
Converting *(pointer+n) to pointer[n] [224] SPRITES_COLOR[*processChars::$37] = processChars::$62[OFFSET_STRUCT_PROCESSINGSPRITE_COL] -- processChars::$63[OFFSET_STRUCT_PROCESSINGSPRITE_ID]
|
||||
Converting *(pointer+n) to pointer[n] [227] processChars::$7 = SCREEN+SPRITE_PTRS + *processChars::$38 -- processChars::$64[OFFSET_STRUCT_PROCESSINGSPRITE_ID]
|
||||
Converting *(pointer+n) to pointer[n] [227] processChars::$7 = SCREEN+OFFSET_SPRITE_PTRS + *processChars::$38 -- processChars::$64[OFFSET_STRUCT_PROCESSINGSPRITE_ID]
|
||||
Converting *(pointer+n) to pointer[n] [230] *processChars::$7 = *processChars::$39 -- processChars::$65[OFFSET_STRUCT_PROCESSINGSPRITE_PTR]
|
||||
Converting *(pointer+n) to pointer[n] [230] *processChars::$7 = processChars::$65[OFFSET_STRUCT_PROCESSINGSPRITE_PTR] -- (SCREEN+SPRITE_PTRS)[processChars::$64[OFFSET_STRUCT_PROCESSINGSPRITE_ID]]
|
||||
Converting *(pointer+n) to pointer[n] [230] *processChars::$7 = processChars::$65[OFFSET_STRUCT_PROCESSINGSPRITE_PTR] -- (SCREEN+OFFSET_SPRITE_PTRS)[processChars::$64[OFFSET_STRUCT_PROCESSINGSPRITE_ID]]
|
||||
Converting *(pointer+n) to pointer[n] [233] *processChars::$40 = STATUS_PROCESSING -- processChars::$66[OFFSET_STRUCT_PROCESSINGSPRITE_STATUS]
|
||||
Converting *(pointer+n) to pointer[n] [241] processChars::$12 = *processChars::$41 >> 4 -- processChars::$67[OFFSET_STRUCT_PROCESSINGSPRITE_Y]
|
||||
Converting *(pointer+n) to pointer[n] [247] processChars::$14 = *processChars::$42 < XPOS_LEFTMOST -- processChars::$68[OFFSET_STRUCT_PROCESSINGSPRITE_X]
|
||||
@ -2613,7 +2613,7 @@ Eliminating unused variable processChars::$35 and assignment [169] processChars:
|
||||
Eliminating unused variable processChars::$36 and assignment [173] processChars::$36 = processChars::$62 + OFFSET_STRUCT_PROCESSINGSPRITE_COL
|
||||
Eliminating unused variable processChars::$37 and assignment [175] processChars::$37 = processChars::$63 + OFFSET_STRUCT_PROCESSINGSPRITE_ID
|
||||
Eliminating unused variable processChars::$38 and assignment [178] processChars::$38 = processChars::$64 + OFFSET_STRUCT_PROCESSINGSPRITE_ID
|
||||
Eliminating unused variable processChars::$7 and assignment [179] processChars::$7 = SCREEN+SPRITE_PTRS + processChars::$64[OFFSET_STRUCT_PROCESSINGSPRITE_ID]
|
||||
Eliminating unused variable processChars::$7 and assignment [179] processChars::$7 = SCREEN+OFFSET_SPRITE_PTRS + processChars::$64[OFFSET_STRUCT_PROCESSINGSPRITE_ID]
|
||||
Eliminating unused variable processChars::$39 and assignment [181] processChars::$39 = processChars::$65 + OFFSET_STRUCT_PROCESSINGSPRITE_PTR
|
||||
Eliminating unused variable processChars::$40 and assignment [184] processChars::$40 = processChars::$66 + OFFSET_STRUCT_PROCESSINGSPRITE_STATUS
|
||||
Eliminating unused variable processChars::$41 and assignment [192] processChars::$41 = processChars::$67 + OFFSET_STRUCT_PROCESSINGSPRITE_Y
|
||||
@ -3204,7 +3204,7 @@ processChars::@11: scope:[processChars] from processChars::@10
|
||||
[71] *(((byte**)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_SCREENPTR]) = ' '
|
||||
[72] *SPRITES_ENABLE = *SPRITES_ENABLE | processChars::bitmask#0
|
||||
[73] SPRITES_COLOR[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_COL]
|
||||
[74] (SCREEN+SPRITE_PTRS)[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_PTR]
|
||||
[74] (SCREEN+OFFSET_SPRITE_PTRS)[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_PTR]
|
||||
[75] ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_STATUS] = STATUS_PROCESSING
|
||||
to:processChars::@3
|
||||
processChars::@3: scope:[processChars] from processChars::@10 processChars::@11
|
||||
@ -4341,7 +4341,7 @@ Removing always clobbered register reg byte x as potential for zp[1]:73 [ proces
|
||||
Removing always clobbered register reg byte x as potential for zp[1]:80 [ processChars::bitmask#0 ]
|
||||
Statement [72] *SPRITES_ENABLE = *SPRITES_ENABLE | processChars::bitmask#0 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] { } ) always clobbers reg byte a
|
||||
Statement [73] SPRITES_COLOR[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_COL] [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] { } ) always clobbers reg byte a reg byte y
|
||||
Statement [74] (SCREEN+SPRITE_PTRS)[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_PTR] [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] { } ) always clobbers reg byte a reg byte y
|
||||
Statement [74] (SCREEN+OFFSET_SPRITE_PTRS)[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_PTR] [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] { } ) always clobbers reg byte a reg byte y
|
||||
Statement [75] ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_STATUS] = STATUS_PROCESSING [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] { } ) always clobbers reg byte a reg byte y
|
||||
Statement [76] processChars::xpos#0 = *((word*)processChars::processing#0) >> 4 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 processChars::xpos#0 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 processChars::xpos#0 ] { } ) always clobbers reg byte a reg byte y
|
||||
Statement [79] processChars::$10 = $ff ^ processChars::bitmask#0 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 processChars::xpos#0 processChars::$10 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 processChars::xpos#0 processChars::$10 ] { } ) always clobbers reg byte a
|
||||
@ -4559,7 +4559,7 @@ Statement [70] if(((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSP
|
||||
Statement [71] *(((byte**)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_SCREENPTR]) = ' ' [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] { } ) always clobbers reg byte a reg byte x reg byte y
|
||||
Statement [72] *SPRITES_ENABLE = *SPRITES_ENABLE | processChars::bitmask#0 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] { } ) always clobbers reg byte a
|
||||
Statement [73] SPRITES_COLOR[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_COL] [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] { } ) always clobbers reg byte a reg byte y
|
||||
Statement [74] (SCREEN+SPRITE_PTRS)[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_PTR] [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] { } ) always clobbers reg byte a reg byte y
|
||||
Statement [74] (SCREEN+OFFSET_SPRITE_PTRS)[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_PTR] [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] { } ) always clobbers reg byte a reg byte y
|
||||
Statement [75] ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_STATUS] = STATUS_PROCESSING [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 ] { } ) always clobbers reg byte a reg byte y
|
||||
Statement [76] processChars::xpos#0 = *((word*)processChars::processing#0) >> 4 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 processChars::xpos#0 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 processChars::xpos#0 ] { } ) always clobbers reg byte a reg byte y
|
||||
Statement [79] processChars::$10 = $ff ^ processChars::bitmask#0 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 processChars::xpos#0 processChars::$10 ] ( processChars:11 [ processChars::i#10 processChars::numActive#10 processChars::$13 processChars::processing#0 processChars::bitmask#0 processChars::xpos#0 processChars::$10 ] { } ) always clobbers reg byte a
|
||||
@ -5090,7 +5090,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
.const BORDER_YPOS_TOP = $32
|
||||
.const BORDER_YPOS_BOTTOM = $fa
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
// Bits for the VICII IRQ Status/Enable Registers
|
||||
.const IRQ_RASTER = 1
|
||||
// Mask for PROCESSOR_PORT_DDR which allows only memory configuration to be written
|
||||
@ -5587,7 +5587,7 @@ processChars: {
|
||||
tay
|
||||
pla
|
||||
sta SPRITES_COLOR,y
|
||||
// [74] (SCREEN+SPRITE_PTRS)[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_PTR] -- pbuc1_derefidx_(pbuz1_derefidx_vbuc2)=pbuz1_derefidx_vbuc3
|
||||
// [74] (SCREEN+OFFSET_SPRITE_PTRS)[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_PTR] -- pbuc1_derefidx_(pbuz1_derefidx_vbuc2)=pbuz1_derefidx_vbuc3
|
||||
// Set sprite pointer
|
||||
ldy #OFFSET_STRUCT_PROCESSINGSPRITE_PTR
|
||||
lda (processing),y
|
||||
@ -5596,7 +5596,7 @@ processChars: {
|
||||
lda (processing),y
|
||||
tay
|
||||
pla
|
||||
sta SCREEN+SPRITE_PTRS,y
|
||||
sta SCREEN+OFFSET_SPRITE_PTRS,y
|
||||
// [75] ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_STATUS] = STATUS_PROCESSING -- pbuz1_derefidx_vbuc1=vbuc2
|
||||
// Set status
|
||||
lda #STATUS_PROCESSING
|
||||
@ -7349,6 +7349,7 @@ const nomodify byte* IRQ_STATUS = (byte*) 53273
|
||||
const nomodify byte LIGHT_BLUE = $e
|
||||
const nomodify byte NOT_FOUND = $ff
|
||||
const nomodify byte NUM_PROCESSING = 8
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_INTERRUPT = $d
|
||||
const byte OFFSET_STRUCT_PROCESSINGSPRITE_COL = $a
|
||||
const byte OFFSET_STRUCT_PROCESSINGSPRITE_ID = 8
|
||||
@ -7386,7 +7387,6 @@ const nomodify byte* SPRITES_XMSB = (byte*) 53264
|
||||
const nomodify byte* SPRITES_XPOS = (byte*) 53248
|
||||
const nomodify byte* SPRITES_YPOS = (byte*) 53249
|
||||
const nomodify byte* SPRITE_DATA = (byte*) 8192
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const byte STATUS_FREE = 0
|
||||
const byte STATUS_NEW = 1
|
||||
const byte STATUS_PROCESSING = 2
|
||||
@ -7798,7 +7798,7 @@ Score: 1110954
|
||||
.const BORDER_YPOS_TOP = $32
|
||||
.const BORDER_YPOS_BOTTOM = $fa
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
// Bits for the VICII IRQ Status/Enable Registers
|
||||
.const IRQ_RASTER = 1
|
||||
// Mask for PROCESSOR_PORT_DDR which allows only memory configuration to be written
|
||||
@ -8270,8 +8270,8 @@ processChars: {
|
||||
tay
|
||||
pla
|
||||
sta SPRITES_COLOR,y
|
||||
// *(SCREEN+SPRITE_PTRS+processing->id) = processing->ptr
|
||||
// [74] (SCREEN+SPRITE_PTRS)[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_PTR] -- pbuc1_derefidx_(pbuz1_derefidx_vbuc2)=pbuz1_derefidx_vbuc3
|
||||
// *(SCREEN+OFFSET_SPRITE_PTRS+processing->id) = processing->ptr
|
||||
// [74] (SCREEN+OFFSET_SPRITE_PTRS)[((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_ID]] = ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_PTR] -- pbuc1_derefidx_(pbuz1_derefidx_vbuc2)=pbuz1_derefidx_vbuc3
|
||||
// Set sprite pointer
|
||||
ldy #OFFSET_STRUCT_PROCESSINGSPRITE_PTR
|
||||
lda (processing),y
|
||||
@ -8280,7 +8280,7 @@ processChars: {
|
||||
lda (processing),y
|
||||
tay
|
||||
pla
|
||||
sta SCREEN+SPRITE_PTRS,y
|
||||
sta SCREEN+OFFSET_SPRITE_PTRS,y
|
||||
// processing->status = STATUS_PROCESSING
|
||||
// [75] ((byte*)processChars::processing#0)[OFFSET_STRUCT_PROCESSINGSPRITE_STATUS] = STATUS_PROCESSING -- pbuz1_derefidx_vbuc1=vbuc2
|
||||
// Set status
|
||||
|
@ -19,6 +19,7 @@ const nomodify byte* IRQ_STATUS = (byte*) 53273
|
||||
const nomodify byte LIGHT_BLUE = $e
|
||||
const nomodify byte NOT_FOUND = $ff
|
||||
const nomodify byte NUM_PROCESSING = 8
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_INTERRUPT = $d
|
||||
const byte OFFSET_STRUCT_PROCESSINGSPRITE_COL = $a
|
||||
const byte OFFSET_STRUCT_PROCESSINGSPRITE_ID = 8
|
||||
@ -56,7 +57,6 @@ const nomodify byte* SPRITES_XMSB = (byte*) 53264
|
||||
const nomodify byte* SPRITES_XPOS = (byte*) 53248
|
||||
const nomodify byte* SPRITES_YPOS = (byte*) 53249
|
||||
const nomodify byte* SPRITE_DATA = (byte*) 8192
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const byte STATUS_FREE = 0
|
||||
const byte STATUS_NEW = 1
|
||||
const byte STATUS_PROCESSING = 2
|
||||
|
@ -14,7 +14,7 @@
|
||||
// Value that disables all CIA interrupts when stored to the CIA Interrupt registers
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
// Bits for the VICII IRQ Status/Enable Registers
|
||||
.const IRQ_RASTER = 1
|
||||
// Mask for PROCESSOR_PORT_DDR which allows only memory configuration to be written
|
||||
@ -60,9 +60,9 @@
|
||||
// Address of the second screen
|
||||
.label PLAYFIELD_SCREEN_2 = $2c00
|
||||
// Screen Sprite pointers on screen 1
|
||||
.label PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+SPRITE_PTRS
|
||||
.label PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+OFFSET_SPRITE_PTRS
|
||||
// Screen Sprite pointers on screen 2
|
||||
.label PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+SPRITE_PTRS
|
||||
.label PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+OFFSET_SPRITE_PTRS
|
||||
// The screen currently being showed to the user. 0x00 for screen 1 / 0x20 for screen 2.
|
||||
.label render_screen_showing = 6
|
||||
// The raster line of the next IRQ
|
||||
|
@ -362,6 +362,7 @@ const nomodify byte* IRQ_ENABLE = (byte*)$d01a
|
||||
const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte IRQ_RASTER_FIRST = (byte)SPRITES_FIRST_YPOS+$13
|
||||
const nomodify byte* IRQ_STATUS = (byte*)$d019
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_INTERRUPT = $d
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_PORT_A = 0
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_PORT_A_DDR = 2
|
||||
@ -385,8 +386,8 @@ const byte* PLAYFIELD_SPRITES[$1e*$40] = kickasm {{ .var sprites = LoadPicture(
|
||||
}
|
||||
}
|
||||
}}
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* PROCPORT = (byte*)1
|
||||
const nomodify byte* PROCPORT_DDR = (byte*)0
|
||||
const nomodify byte PROCPORT_DDR_MEMORY_MASK = 7
|
||||
@ -407,7 +408,6 @@ const nomodify byte SPRITES_FIRST_YPOS = $31
|
||||
const nomodify byte* SPRITES_MC = (byte*)$d01c
|
||||
const nomodify byte* SPRITES_XPOS = (byte*)$d000
|
||||
const nomodify byte* SPRITES_YPOS = (byte*)$d001
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const nomodify byte* VICII_CONTROL = (byte*)$d011
|
||||
void __start()
|
||||
byte~ __start::__init1_$0
|
||||
@ -1687,7 +1687,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
// Value that disables all CIA interrupts when stored to the CIA Interrupt registers
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
// Bits for the VICII IRQ Status/Enable Registers
|
||||
.const IRQ_RASTER = 1
|
||||
// Mask for PROCESSOR_PORT_DDR which allows only memory configuration to be written
|
||||
@ -1733,9 +1733,9 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
// Address of the second screen
|
||||
.label PLAYFIELD_SCREEN_2 = $2c00
|
||||
// Screen Sprite pointers on screen 1
|
||||
.label PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+SPRITE_PTRS
|
||||
.label PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+OFFSET_SPRITE_PTRS
|
||||
// Screen Sprite pointers on screen 2
|
||||
.label PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+SPRITE_PTRS
|
||||
.label PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+OFFSET_SPRITE_PTRS
|
||||
// The screen currently being showed to the user. 0x00 for screen 1 / 0x20 for screen 2.
|
||||
.label render_screen_showing = 6
|
||||
// The raster line of the next IRQ
|
||||
@ -2400,6 +2400,7 @@ const nomodify byte* IRQ_ENABLE = (byte*) 53274
|
||||
const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte IRQ_RASTER_FIRST = SPRITES_FIRST_YPOS+$13
|
||||
const nomodify byte* IRQ_STATUS = (byte*) 53273
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_INTERRUPT = $d
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_PORT_A_DDR = 2
|
||||
const byte* PLAYFIELD_CHARSET[] = kickasm {{ .fill 8,$00 // Place a filled char at the start of the charset
|
||||
@ -2422,8 +2423,8 @@ const byte* PLAYFIELD_SPRITES[$1e*$40] = kickasm {{ .var sprites = LoadPicture(
|
||||
}
|
||||
}
|
||||
}}
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* PROCPORT = (byte*) 1
|
||||
const nomodify byte* PROCPORT_DDR = (byte*) 0
|
||||
const nomodify byte PROCPORT_DDR_MEMORY_MASK = 7
|
||||
@ -2444,7 +2445,6 @@ const nomodify byte SPRITES_FIRST_YPOS = $31
|
||||
const nomodify byte* SPRITES_MC = (byte*) 53276
|
||||
const nomodify byte* SPRITES_XPOS = (byte*) 53248
|
||||
const nomodify byte* SPRITES_YPOS = (byte*) 53249
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
void __start()
|
||||
byte __start::__init1_toSpritePtr1_return
|
||||
@ -2564,7 +2564,7 @@ Score: 6632
|
||||
// Value that disables all CIA interrupts when stored to the CIA Interrupt registers
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
// Bits for the VICII IRQ Status/Enable Registers
|
||||
.const IRQ_RASTER = 1
|
||||
// Mask for PROCESSOR_PORT_DDR which allows only memory configuration to be written
|
||||
@ -2610,9 +2610,9 @@ Score: 6632
|
||||
// Address of the second screen
|
||||
.label PLAYFIELD_SCREEN_2 = $2c00
|
||||
// Screen Sprite pointers on screen 1
|
||||
.label PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+SPRITE_PTRS
|
||||
.label PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+OFFSET_SPRITE_PTRS
|
||||
// Screen Sprite pointers on screen 2
|
||||
.label PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+SPRITE_PTRS
|
||||
.label PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+OFFSET_SPRITE_PTRS
|
||||
// The screen currently being showed to the user. 0x00 for screen 1 / 0x20 for screen 2.
|
||||
.label render_screen_showing = 6
|
||||
// The raster line of the next IRQ
|
||||
|
@ -9,6 +9,7 @@ const nomodify byte* IRQ_ENABLE = (byte*) 53274
|
||||
const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte IRQ_RASTER_FIRST = SPRITES_FIRST_YPOS+$13
|
||||
const nomodify byte* IRQ_STATUS = (byte*) 53273
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_INTERRUPT = $d
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_PORT_A_DDR = 2
|
||||
const byte* PLAYFIELD_CHARSET[] = kickasm {{ .fill 8,$00 // Place a filled char at the start of the charset
|
||||
@ -31,8 +32,8 @@ const byte* PLAYFIELD_SPRITES[$1e*$40] = kickasm {{ .var sprites = LoadPicture(
|
||||
}
|
||||
}
|
||||
}}
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* PROCPORT = (byte*) 1
|
||||
const nomodify byte* PROCPORT_DDR = (byte*) 0
|
||||
const nomodify byte PROCPORT_DDR_MEMORY_MASK = 7
|
||||
@ -53,7 +54,6 @@ const nomodify byte SPRITES_FIRST_YPOS = $31
|
||||
const nomodify byte* SPRITES_MC = (byte*) 53276
|
||||
const nomodify byte* SPRITES_XPOS = (byte*) 53248
|
||||
const nomodify byte* SPRITES_YPOS = (byte*) 53249
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
void __start()
|
||||
byte __start::__init1_toSpritePtr1_return
|
||||
|
@ -12,7 +12,7 @@
|
||||
// Value that disables all CIA interrupts when stored to the CIA Interrupt registers
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
.const VICII_ECM = $40
|
||||
.const VICII_DEN = $10
|
||||
.const VICII_RSEL = 8
|
||||
@ -112,9 +112,9 @@
|
||||
// Address of the second screen
|
||||
.label PLAYFIELD_SCREEN_2 = $2c00
|
||||
// Screen Sprite pointers on screen 1
|
||||
.label PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+SPRITE_PTRS
|
||||
.label PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+OFFSET_SPRITE_PTRS
|
||||
// Screen Sprite pointers on screen 2
|
||||
.label PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+SPRITE_PTRS
|
||||
.label PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+OFFSET_SPRITE_PTRS
|
||||
// The screen currently being showed to the user. 0x00 for screen 1 / 0x20 for screen 2.
|
||||
.label render_screen_showing = $24
|
||||
// Current score in BCD-format
|
||||
|
@ -3252,6 +3252,7 @@ const nomodify byte KEY_Z = $c
|
||||
const nomodify byte LIGHT_BLUE = $e
|
||||
const nomodify byte LIGHT_GREEN = $d
|
||||
const to_nomodify byte* MOVEDOWN_SLOW_SPEEDS[] = { $30, $2b, $26, $21, $1c, $17, $12, $d, 8, 6, 5, 5, 5, 4, 4, 4, 3, 3, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1 }
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_INTERRUPT = $d
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_PORT_A = 0
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_PORT_A_DDR = 2
|
||||
@ -3308,8 +3309,8 @@ const byte* PLAYFIELD_SPRITES[$1e*$40] = kickasm {{ .var sprites = LoadPicture(
|
||||
}
|
||||
}
|
||||
}}
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* PROCPORT = (byte*)1
|
||||
const nomodify byte* PROCPORT_DDR = (byte*)0
|
||||
const nomodify byte PROCPORT_DDR_MEMORY_MASK = 7
|
||||
@ -3331,7 +3332,6 @@ const nomodify byte SPRITES_FIRST_YPOS = $31
|
||||
const nomodify byte* SPRITES_MC = (byte*)$d01c
|
||||
const nomodify byte* SPRITES_XPOS = (byte*)$d000
|
||||
const nomodify byte* SPRITES_YPOS = (byte*)$d001
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const nomodify byte* VICII_CONTROL = (byte*)$d011
|
||||
const nomodify byte VICII_DEN = $10
|
||||
const nomodify byte VICII_ECM = $40
|
||||
@ -12554,7 +12554,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
// Value that disables all CIA interrupts when stored to the CIA Interrupt registers
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
.const VICII_ECM = $40
|
||||
.const VICII_DEN = $10
|
||||
.const VICII_RSEL = 8
|
||||
@ -12654,9 +12654,9 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
// Address of the second screen
|
||||
.label PLAYFIELD_SCREEN_2 = $2c00
|
||||
// Screen Sprite pointers on screen 1
|
||||
.label PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+SPRITE_PTRS
|
||||
.label PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+OFFSET_SPRITE_PTRS
|
||||
// Screen Sprite pointers on screen 2
|
||||
.label PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+SPRITE_PTRS
|
||||
.label PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+OFFSET_SPRITE_PTRS
|
||||
// The screen currently being showed to the user. 0x00 for screen 1 / 0x20 for screen 2.
|
||||
.label render_screen_showing = $24
|
||||
// Current score in BCD-format
|
||||
@ -16762,6 +16762,7 @@ const nomodify byte KEY_Z = $c
|
||||
const nomodify byte LIGHT_BLUE = $e
|
||||
const nomodify byte LIGHT_GREEN = $d
|
||||
const to_nomodify byte* MOVEDOWN_SLOW_SPEEDS[] = { $30, $2b, $26, $21, $1c, $17, $12, $d, 8, 6, 5, 5, 5, 4, 4, 4, 3, 3, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1 }
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_INTERRUPT = $d
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_PORT_A_DDR = 2
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_PORT_B = 1
|
||||
@ -16817,8 +16818,8 @@ const byte* PLAYFIELD_SPRITES[$1e*$40] = kickasm {{ .var sprites = LoadPicture(
|
||||
}
|
||||
}
|
||||
}}
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* PROCPORT = (byte*) 1
|
||||
const nomodify byte* PROCPORT_DDR = (byte*) 0
|
||||
const nomodify byte PROCPORT_DDR_MEMORY_MASK = 7
|
||||
@ -16837,7 +16838,6 @@ const nomodify byte SPRITES_FIRST_YPOS = $31
|
||||
const nomodify byte* SPRITES_MC = (byte*) 53276
|
||||
const nomodify byte* SPRITES_XPOS = (byte*) 53248
|
||||
const nomodify byte* SPRITES_YPOS = (byte*) 53249
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
const nomodify byte VICII_DEN = $10
|
||||
const nomodify byte VICII_ECM = $40
|
||||
@ -17614,7 +17614,7 @@ Score: 3343892
|
||||
// Value that disables all CIA interrupts when stored to the CIA Interrupt registers
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
.const VICII_ECM = $40
|
||||
.const VICII_DEN = $10
|
||||
.const VICII_RSEL = 8
|
||||
@ -17714,9 +17714,9 @@ Score: 3343892
|
||||
// Address of the second screen
|
||||
.label PLAYFIELD_SCREEN_2 = $2c00
|
||||
// Screen Sprite pointers on screen 1
|
||||
.label PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+SPRITE_PTRS
|
||||
.label PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+OFFSET_SPRITE_PTRS
|
||||
// Screen Sprite pointers on screen 2
|
||||
.label PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+SPRITE_PTRS
|
||||
.label PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+OFFSET_SPRITE_PTRS
|
||||
// The screen currently being showed to the user. 0x00 for screen 1 / 0x20 for screen 2.
|
||||
.label render_screen_showing = $24
|
||||
// Current score in BCD-format
|
||||
|
@ -38,6 +38,7 @@ const nomodify byte KEY_Z = $c
|
||||
const nomodify byte LIGHT_BLUE = $e
|
||||
const nomodify byte LIGHT_GREEN = $d
|
||||
const to_nomodify byte* MOVEDOWN_SLOW_SPEEDS[] = { $30, $2b, $26, $21, $1c, $17, $12, $d, 8, 6, 5, 5, 5, 4, 4, 4, 3, 3, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1 }
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_INTERRUPT = $d
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_PORT_A_DDR = 2
|
||||
const byte OFFSET_STRUCT_MOS6526_CIA_PORT_B = 1
|
||||
@ -93,8 +94,8 @@ const byte* PLAYFIELD_SPRITES[$1e*$40] = kickasm {{ .var sprites = LoadPicture(
|
||||
}
|
||||
}
|
||||
}}
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_1 = PLAYFIELD_SCREEN_1+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* PLAYFIELD_SPRITE_PTRS_2 = PLAYFIELD_SCREEN_2+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* PROCPORT = (byte*) 1
|
||||
const nomodify byte* PROCPORT_DDR = (byte*) 0
|
||||
const nomodify byte PROCPORT_DDR_MEMORY_MASK = 7
|
||||
@ -113,7 +114,6 @@ const nomodify byte SPRITES_FIRST_YPOS = $31
|
||||
const nomodify byte* SPRITES_MC = (byte*) 53276
|
||||
const nomodify byte* SPRITES_XPOS = (byte*) 53248
|
||||
const nomodify byte* SPRITES_YPOS = (byte*) 53249
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
const nomodify byte VICII_DEN = $10
|
||||
const nomodify byte VICII_ECM = $40
|
||||
|
@ -13,7 +13,7 @@
|
||||
.const JMP = $4c
|
||||
.const NOP = $ea
|
||||
.label RASTER = $d012
|
||||
.label VIC_MEMORY = $d018
|
||||
.label VICII_MEMORY = $d018
|
||||
.label SCREEN = $400
|
||||
.label BG_COLOR = $d021
|
||||
.label COLS = $d800
|
||||
@ -36,10 +36,10 @@ main: {
|
||||
// Print message
|
||||
.label sc = 4
|
||||
.label msg = 2
|
||||
// *VIC_MEMORY = 0x14
|
||||
// *VICII_MEMORY = 0x14
|
||||
// Initialize screen memory
|
||||
lda #$14
|
||||
sta VIC_MEMORY
|
||||
sta VICII_MEMORY
|
||||
// memset(SCREEN, ' ', 40*25)
|
||||
// Init screen/colors
|
||||
ldx #' '
|
||||
|
@ -17,7 +17,7 @@ syscall1::@return: scope:[syscall1] from syscall1
|
||||
|
||||
void main()
|
||||
main: scope:[main] from
|
||||
[4] *VIC_MEMORY = $14
|
||||
[4] *VICII_MEMORY = $14
|
||||
[5] call memset
|
||||
to:main::@6
|
||||
main::@6: scope:[main] from main
|
||||
|
@ -48,7 +48,7 @@ memset::@return: scope:[memset] from memset::@1
|
||||
|
||||
void main()
|
||||
main: scope:[main] from __start
|
||||
*VIC_MEMORY = $14
|
||||
*VICII_MEMORY = $14
|
||||
memset::str#0 = (void*)SCREEN
|
||||
memset::c#0 = ' '
|
||||
memset::num#0 = $28*$19
|
||||
@ -135,7 +135,7 @@ const nomodify byte* RASTER = (byte*)$d012
|
||||
const nomodify byte* SCREEN = (byte*)$400
|
||||
const struct SysCall* SYSCALLS[] = { { xjmp: JMP, syscall: &syscall1, xnop: NOP }, { xjmp: JMP, syscall: &syscall2, xnop: NOP } }
|
||||
const struct SysCall* SYSCALL_RESET[] = { { xjmp: JMP, syscall: &main, xnop: NOP } }
|
||||
const nomodify byte* VIC_MEMORY = (byte*)$d018
|
||||
const nomodify byte* VICII_MEMORY = (byte*)$d018
|
||||
const nomodify byte WHITE = 1
|
||||
void __start()
|
||||
void main()
|
||||
@ -198,7 +198,7 @@ void syscall1()
|
||||
void syscall2()
|
||||
|
||||
Adding number conversion cast (unumber) 0 in memset::$0 = memset::num#2 > 0
|
||||
Adding number conversion cast (unumber) $14 in *VIC_MEMORY = $14
|
||||
Adding number conversion cast (unumber) $14 in *VICII_MEMORY = $14
|
||||
Adding number conversion cast (unumber) $28*$19 in memset::num#0 = $28*$19
|
||||
Adding number conversion cast (unumber) $28*$19 in memset::num#1 = $28*$19
|
||||
Adding number conversion cast (unumber) $28 in main::sc#0 = SCREEN+$28
|
||||
@ -209,7 +209,7 @@ Adding number conversion cast (unumber) $4f in *(SCREEN+$4f) = '>'
|
||||
Adding number conversion cast (unumber) $4e in *(SCREEN+$4e) = '<'
|
||||
Successful SSA optimization PassNAddNumberTypeConversions
|
||||
Inlining cast memset::dst#0 = (byte*)memset::str#3
|
||||
Inlining cast *VIC_MEMORY = (unumber)$14
|
||||
Inlining cast *VICII_MEMORY = (unumber)$14
|
||||
Inlining cast memset::num#0 = (unumber)$28*$19
|
||||
Inlining cast memset::num#1 = (unumber)$28*$19
|
||||
Successful SSA optimization Pass2InlineCast
|
||||
@ -361,7 +361,7 @@ syscall1::@return: scope:[syscall1] from syscall1
|
||||
|
||||
void main()
|
||||
main: scope:[main] from
|
||||
[4] *VIC_MEMORY = $14
|
||||
[4] *VICII_MEMORY = $14
|
||||
[5] call memset
|
||||
to:main::@6
|
||||
main::@6: scope:[main] from main
|
||||
@ -460,7 +460,7 @@ Allocated zp[2]:11 [ memset::end#0 ]
|
||||
REGISTER UPLIFT POTENTIAL REGISTERS
|
||||
Statement [0] *(SCREEN+$4e) = '<' [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [2] *(SCREEN+$4f) = '>' [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [4] *VIC_MEMORY = $14 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [4] *VICII_MEMORY = $14 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [9] if(0!=*main::msg#2) goto main::@2 [ main::msg#2 main::sc#2 ] ( [ main::msg#2 main::sc#2 ] { } ) always clobbers reg byte a reg byte y
|
||||
Statement [10] if(*RASTER==$36) goto main::@4 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [11] if(*RASTER==$42) goto main::@4 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
@ -475,7 +475,7 @@ Statement [23] *memset::dst#2 = memset::c#4 [ memset::c#4 memset::end#0 memset::
|
||||
Removing always clobbered register reg byte y as potential for zp[1]:8 [ memset::c#4 ]
|
||||
Statement [0] *(SCREEN+$4e) = '<' [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [2] *(SCREEN+$4f) = '>' [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [4] *VIC_MEMORY = $14 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [4] *VICII_MEMORY = $14 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [9] if(0!=*main::msg#2) goto main::@2 [ main::msg#2 main::sc#2 ] ( [ main::msg#2 main::sc#2 ] { } ) always clobbers reg byte a reg byte y
|
||||
Statement [10] if(*RASTER==$36) goto main::@4 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [11] if(*RASTER==$42) goto main::@4 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
@ -529,7 +529,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
.const JMP = $4c
|
||||
.const NOP = $ea
|
||||
.label RASTER = $d012
|
||||
.label VIC_MEMORY = $d018
|
||||
.label VICII_MEMORY = $d018
|
||||
.label SCREEN = $400
|
||||
.label BG_COLOR = $d021
|
||||
.label COLS = $d800
|
||||
@ -561,10 +561,10 @@ main: {
|
||||
// Print message
|
||||
.label sc = 4
|
||||
.label msg = 2
|
||||
// [4] *VIC_MEMORY = $14 -- _deref_pbuc1=vbuc2
|
||||
// [4] *VICII_MEMORY = $14 -- _deref_pbuc1=vbuc2
|
||||
// Initialize screen memory
|
||||
lda #$14
|
||||
sta VIC_MEMORY
|
||||
sta VICII_MEMORY
|
||||
// [5] call memset
|
||||
// Init screen/colors
|
||||
// [17] phi from main to memset [phi:main->memset]
|
||||
@ -772,7 +772,7 @@ const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* SCREEN = (byte*) 1024
|
||||
const struct SysCall* SYSCALLS[] = { { xjmp: JMP, syscall: &syscall1, xnop: NOP }, { xjmp: JMP, syscall: &syscall2, xnop: NOP } }
|
||||
const struct SysCall* SYSCALL_RESET[] = { { xjmp: JMP, syscall: &main, xnop: NOP } }
|
||||
const nomodify byte* VIC_MEMORY = (byte*) 53272
|
||||
const nomodify byte* VICII_MEMORY = (byte*) 53272
|
||||
const nomodify byte WHITE = 1
|
||||
void main()
|
||||
byte* main::msg
|
||||
@ -825,7 +825,7 @@ Score: 1600
|
||||
.const JMP = $4c
|
||||
.const NOP = $ea
|
||||
.label RASTER = $d012
|
||||
.label VIC_MEMORY = $d018
|
||||
.label VICII_MEMORY = $d018
|
||||
.label SCREEN = $400
|
||||
.label BG_COLOR = $d021
|
||||
.label COLS = $d800
|
||||
@ -857,11 +857,11 @@ main: {
|
||||
// Print message
|
||||
.label sc = 4
|
||||
.label msg = 2
|
||||
// *VIC_MEMORY = 0x14
|
||||
// [4] *VIC_MEMORY = $14 -- _deref_pbuc1=vbuc2
|
||||
// *VICII_MEMORY = 0x14
|
||||
// [4] *VICII_MEMORY = $14 -- _deref_pbuc1=vbuc2
|
||||
// Initialize screen memory
|
||||
lda #$14
|
||||
sta VIC_MEMORY
|
||||
sta VICII_MEMORY
|
||||
// memset(SCREEN, ' ', 40*25)
|
||||
// [5] call memset
|
||||
// Init screen/colors
|
||||
|
@ -8,7 +8,7 @@ const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* SCREEN = (byte*) 1024
|
||||
const struct SysCall* SYSCALLS[] = { { xjmp: JMP, syscall: &syscall1, xnop: NOP }, { xjmp: JMP, syscall: &syscall2, xnop: NOP } }
|
||||
const struct SysCall* SYSCALL_RESET[] = { { xjmp: JMP, syscall: &main, xnop: NOP } }
|
||||
const nomodify byte* VIC_MEMORY = (byte*) 53272
|
||||
const nomodify byte* VICII_MEMORY = (byte*) 53272
|
||||
const nomodify byte WHITE = 1
|
||||
void main()
|
||||
byte* main::msg
|
||||
|
@ -15,7 +15,7 @@
|
||||
:BasicUpstart(main)
|
||||
.segment Code
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
.const GREEN = 5
|
||||
.const OFFSET_STRUCT_MOS6569_VICII_SPRITES_ENABLE = $15
|
||||
.const OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR = $20
|
||||
@ -27,7 +27,7 @@
|
||||
// Address to load to
|
||||
.label LOAD_SPRITE = $3000
|
||||
.label SCREEN = $400
|
||||
.label SPRITES_PTR = SCREEN+SPRITE_PTRS
|
||||
.label SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS
|
||||
.segment Code
|
||||
main: {
|
||||
.const toSpritePtr1_return = LOAD_SPRITE/$40
|
||||
|
@ -180,6 +180,7 @@ __start::@return: scope:[__start] from __start::@1
|
||||
SYMBOL TABLE SSA
|
||||
const nomodify byte GREEN = 5
|
||||
const nomodify byte* LOAD_SPRITE = (byte*)$3000
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR = $20
|
||||
const byte OFFSET_STRUCT_MOS6569_VICII_SPRITES_ENABLE = $15
|
||||
const nomodify byte* SCREEN = (byte*)$400
|
||||
@ -189,10 +190,9 @@ const byte* SPRITE[] = kickasm {{ .var pic = LoadPicture("sprite.png", List().a
|
||||
.byte pic.getSinglecolorByte(x,y)
|
||||
}}
|
||||
const nomodify byte* SPRITES_COLOR = (byte*)$d027
|
||||
const nomodify byte* SPRITES_PTR = SCREEN+SPRITE_PTRS
|
||||
const nomodify byte* SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* SPRITES_XPOS = (byte*)$d000
|
||||
const nomodify byte* SPRITES_YPOS = (byte*)$d001
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const nomodify struct MOS6569_VICII* VICII = (struct MOS6569_VICII*)$d000
|
||||
void __start()
|
||||
void error(byte error::err)
|
||||
@ -740,7 +740,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
.segment Code
|
||||
// Global Constants & labels
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
.const GREEN = 5
|
||||
.const OFFSET_STRUCT_MOS6569_VICII_SPRITES_ENABLE = $15
|
||||
.const OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR = $20
|
||||
@ -752,7 +752,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
// Address to load to
|
||||
.label LOAD_SPRITE = $3000
|
||||
.label SCREEN = $400
|
||||
.label SPRITES_PTR = SCREEN+SPRITE_PTRS
|
||||
.label SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS
|
||||
.segment Code
|
||||
// main
|
||||
main: {
|
||||
@ -1068,6 +1068,7 @@ Succesful ASM optimization Pass5UnusedLabelElimination
|
||||
FINAL SYMBOL TABLE
|
||||
const nomodify byte GREEN = 5
|
||||
const nomodify byte* LOAD_SPRITE = (byte*) 12288
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR = $20
|
||||
const byte OFFSET_STRUCT_MOS6569_VICII_SPRITES_ENABLE = $15
|
||||
const nomodify byte* SCREEN = (byte*) 1024
|
||||
@ -1077,10 +1078,9 @@ const byte* SPRITE[] = kickasm {{ .var pic = LoadPicture("sprite.png", List().a
|
||||
.byte pic.getSinglecolorByte(x,y)
|
||||
}}
|
||||
const nomodify byte* SPRITES_COLOR = (byte*) 53287
|
||||
const nomodify byte* SPRITES_PTR = SCREEN+SPRITE_PTRS
|
||||
const nomodify byte* SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* SPRITES_XPOS = (byte*) 53248
|
||||
const nomodify byte* SPRITES_YPOS = (byte*) 53249
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const nomodify struct MOS6569_VICII* VICII = (struct MOS6569_VICII*) 53248
|
||||
void error(byte error::err)
|
||||
byte error::err
|
||||
@ -1161,7 +1161,7 @@ Score: 811
|
||||
.segment Code
|
||||
// Global Constants & labels
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
.const GREEN = 5
|
||||
.const OFFSET_STRUCT_MOS6569_VICII_SPRITES_ENABLE = $15
|
||||
.const OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR = $20
|
||||
@ -1173,7 +1173,7 @@ Score: 811
|
||||
// Address to load to
|
||||
.label LOAD_SPRITE = $3000
|
||||
.label SCREEN = $400
|
||||
.label SPRITES_PTR = SCREEN+SPRITE_PTRS
|
||||
.label SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS
|
||||
.segment Code
|
||||
// main
|
||||
main: {
|
||||
|
@ -1,5 +1,6 @@
|
||||
const nomodify byte GREEN = 5
|
||||
const nomodify byte* LOAD_SPRITE = (byte*) 12288
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR = $20
|
||||
const byte OFFSET_STRUCT_MOS6569_VICII_SPRITES_ENABLE = $15
|
||||
const nomodify byte* SCREEN = (byte*) 1024
|
||||
@ -9,10 +10,9 @@ const byte* SPRITE[] = kickasm {{ .var pic = LoadPicture("sprite.png", List().a
|
||||
.byte pic.getSinglecolorByte(x,y)
|
||||
}}
|
||||
const nomodify byte* SPRITES_COLOR = (byte*) 53287
|
||||
const nomodify byte* SPRITES_PTR = SCREEN+SPRITE_PTRS
|
||||
const nomodify byte* SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* SPRITES_XPOS = (byte*) 53248
|
||||
const nomodify byte* SPRITES_YPOS = (byte*) 53249
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const nomodify struct MOS6569_VICII* VICII = (struct MOS6569_VICII*) 53248
|
||||
void error(byte error::err)
|
||||
byte error::err
|
||||
|
@ -17,7 +17,7 @@
|
||||
.segment Code
|
||||
.const KRILL_OK = 0
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
.const GREEN = 5
|
||||
.const OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR = $20
|
||||
.const OFFSET_STRUCT_MOS6569_VICII_SPRITES_ENABLE = $15
|
||||
@ -27,7 +27,7 @@
|
||||
// The VIC-II MOS 6567/6569
|
||||
.label VICII = $d000
|
||||
.label SCREEN = $400
|
||||
.label SPRITES_PTR = SCREEN+SPRITE_PTRS
|
||||
.label SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS
|
||||
.segment Code
|
||||
main: {
|
||||
.const toSpritePtr1_return = $ff&SPRITE/$40
|
||||
|
@ -109,6 +109,7 @@ const byte KrillStatus::KRILL_FILE_NOT_FOUND = $ff
|
||||
const byte KrillStatus::KRILL_GENERIC_KERNAL_ERROR = $fd
|
||||
const byte KrillStatus::KRILL_OK = 0
|
||||
const byte KrillStatus::KRILL_TOO_MANY_DEVICES = $fc
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR = $20
|
||||
const byte OFFSET_STRUCT_MOS6569_VICII_SPRITES_ENABLE = $15
|
||||
const nomodify byte* SCREEN = (byte*)$400
|
||||
@ -118,10 +119,9 @@ const byte* SPRITE[$40] = kickasm {{ .var pic = LoadPicture("sprite.png", List(
|
||||
.byte pic.getSinglecolorByte(x,y)
|
||||
}}
|
||||
const nomodify byte* SPRITES_COLOR = (byte*)$d027
|
||||
const nomodify byte* SPRITES_PTR = SCREEN+SPRITE_PTRS
|
||||
const nomodify byte* SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* SPRITES_XPOS = (byte*)$d000
|
||||
const nomodify byte* SPRITES_YPOS = (byte*)$d001
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const nomodify struct MOS6569_VICII* VICII = (struct MOS6569_VICII*)$d000
|
||||
void __start()
|
||||
byte krill_install()
|
||||
@ -445,7 +445,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
// Global Constants & labels
|
||||
.const KRILL_OK = 0
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
.const GREEN = 5
|
||||
.const OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR = $20
|
||||
.const OFFSET_STRUCT_MOS6569_VICII_SPRITES_ENABLE = $15
|
||||
@ -455,7 +455,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
// The VIC-II MOS 6567/6569
|
||||
.label VICII = $d000
|
||||
.label SCREEN = $400
|
||||
.label SPRITES_PTR = SCREEN+SPRITE_PTRS
|
||||
.label SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS
|
||||
.segment Code
|
||||
// main
|
||||
main: {
|
||||
@ -654,6 +654,7 @@ const byte KrillStatus::KRILL_FILE_NOT_FOUND = $ff
|
||||
const byte KrillStatus::KRILL_GENERIC_KERNAL_ERROR = $fd
|
||||
const byte KrillStatus::KRILL_OK = 0
|
||||
const byte KrillStatus::KRILL_TOO_MANY_DEVICES = $fc
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR = $20
|
||||
const byte OFFSET_STRUCT_MOS6569_VICII_SPRITES_ENABLE = $15
|
||||
const nomodify byte* SCREEN = (byte*) 1024
|
||||
@ -663,10 +664,9 @@ const byte* SPRITE[$40] = kickasm {{ .var pic = LoadPicture("sprite.png", List(
|
||||
.byte pic.getSinglecolorByte(x,y)
|
||||
}}
|
||||
const nomodify byte* SPRITES_COLOR = (byte*) 53287
|
||||
const nomodify byte* SPRITES_PTR = SCREEN+SPRITE_PTRS
|
||||
const nomodify byte* SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* SPRITES_XPOS = (byte*) 53248
|
||||
const nomodify byte* SPRITES_YPOS = (byte*) 53249
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const nomodify struct MOS6569_VICII* VICII = (struct MOS6569_VICII*) 53248
|
||||
byte krill_install()
|
||||
byte krill_install::return
|
||||
@ -722,7 +722,7 @@ Score: 130
|
||||
// Global Constants & labels
|
||||
.const KRILL_OK = 0
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
.const GREEN = 5
|
||||
.const OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR = $20
|
||||
.const OFFSET_STRUCT_MOS6569_VICII_SPRITES_ENABLE = $15
|
||||
@ -732,7 +732,7 @@ Score: 130
|
||||
// The VIC-II MOS 6567/6569
|
||||
.label VICII = $d000
|
||||
.label SCREEN = $400
|
||||
.label SPRITES_PTR = SCREEN+SPRITE_PTRS
|
||||
.label SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS
|
||||
.segment Code
|
||||
// main
|
||||
main: {
|
||||
|
@ -10,6 +10,7 @@ const byte KrillStatus::KRILL_FILE_NOT_FOUND = $ff
|
||||
const byte KrillStatus::KRILL_GENERIC_KERNAL_ERROR = $fd
|
||||
const byte KrillStatus::KRILL_OK = 0
|
||||
const byte KrillStatus::KRILL_TOO_MANY_DEVICES = $fc
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const byte OFFSET_STRUCT_MOS6569_VICII_BORDER_COLOR = $20
|
||||
const byte OFFSET_STRUCT_MOS6569_VICII_SPRITES_ENABLE = $15
|
||||
const nomodify byte* SCREEN = (byte*) 1024
|
||||
@ -19,10 +20,9 @@ const byte* SPRITE[$40] = kickasm {{ .var pic = LoadPicture("sprite.png", List(
|
||||
.byte pic.getSinglecolorByte(x,y)
|
||||
}}
|
||||
const nomodify byte* SPRITES_COLOR = (byte*) 53287
|
||||
const nomodify byte* SPRITES_PTR = SCREEN+SPRITE_PTRS
|
||||
const nomodify byte* SPRITES_PTR = SCREEN+OFFSET_SPRITE_PTRS
|
||||
const nomodify byte* SPRITES_XPOS = (byte*) 53248
|
||||
const nomodify byte* SPRITES_YPOS = (byte*) 53249
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const nomodify struct MOS6569_VICII* VICII = (struct MOS6569_VICII*) 53248
|
||||
byte krill_install()
|
||||
byte krill_install::return
|
||||
|
@ -7,8 +7,8 @@
|
||||
.segmentdef Data [startAfter="Code"]
|
||||
.segment Basic
|
||||
:BasicUpstart(main)
|
||||
.label VIC_RASTER = $d012
|
||||
.label VIC_BG_COLOR = $d020
|
||||
.label VICII_RASTER = $d012
|
||||
.label VICII_BG_COLOR = $d020
|
||||
.label SCREEN = $400
|
||||
.segment Code
|
||||
main: {
|
||||
@ -20,13 +20,13 @@ main: {
|
||||
sei
|
||||
// Wait for raster refresh
|
||||
__b1:
|
||||
// while(*VIC_RASTER!=0xff)
|
||||
// while(*VICII_RASTER!=0xff)
|
||||
lda #$ff
|
||||
cmp VIC_RASTER
|
||||
cmp VICII_RASTER
|
||||
bne __b1
|
||||
// *VIC_BG_COLOR = 0
|
||||
// *VICII_BG_COLOR = 0
|
||||
lda #0
|
||||
sta VIC_BG_COLOR
|
||||
sta VICII_BG_COLOR
|
||||
lda #<SCREEN
|
||||
sta.z line
|
||||
lda #>SCREEN
|
||||
@ -38,9 +38,9 @@ main: {
|
||||
lda.z i
|
||||
cmp #$19
|
||||
bcc __b4
|
||||
// *VIC_BG_COLOR = 15
|
||||
// *VICII_BG_COLOR = 15
|
||||
lda #$f
|
||||
sta VIC_BG_COLOR
|
||||
sta VICII_BG_COLOR
|
||||
jmp __b1
|
||||
__b4:
|
||||
// line[(char)entities[i]] = ' '
|
||||
|
@ -4,10 +4,10 @@ main: scope:[main] from
|
||||
asm { sei }
|
||||
to:main::@1
|
||||
main::@1: scope:[main] from main main::@1 main::@5
|
||||
[1] if(*VIC_RASTER!=$ff) goto main::@1
|
||||
[1] if(*VICII_RASTER!=$ff) goto main::@1
|
||||
to:main::@2
|
||||
main::@2: scope:[main] from main::@1
|
||||
[2] *VIC_BG_COLOR = 0
|
||||
[2] *VICII_BG_COLOR = 0
|
||||
to:main::@3
|
||||
main::@3: scope:[main] from main::@2 main::@6
|
||||
[3] main::line#2 = phi( main::@2/SCREEN, main::@6/main::line#1 )
|
||||
@ -15,7 +15,7 @@ main::@3: scope:[main] from main::@2 main::@6
|
||||
[4] if(main::i#2<$19) goto main::@4
|
||||
to:main::@5
|
||||
main::@5: scope:[main] from main::@3
|
||||
[5] *VIC_BG_COLOR = $f
|
||||
[5] *VICII_BG_COLOR = $f
|
||||
to:main::@1
|
||||
main::@4: scope:[main] from main::@3
|
||||
[6] main::$7 = main::i#2 << 1
|
||||
|
@ -10,11 +10,11 @@ main::@1: scope:[main] from main main::@6
|
||||
if(main::$10) goto main::@2
|
||||
to:main::@return
|
||||
main::@2: scope:[main] from main::@1 main::@2
|
||||
main::$0 = *VIC_RASTER != $ff
|
||||
main::$0 = *VICII_RASTER != $ff
|
||||
if(main::$0) goto main::@2
|
||||
to:main::@3
|
||||
main::@3: scope:[main] from main::@2
|
||||
*VIC_BG_COLOR = 0
|
||||
*VICII_BG_COLOR = 0
|
||||
main::line#0 = SCREEN
|
||||
main::i#0 = 0
|
||||
to:main::@4
|
||||
@ -38,7 +38,7 @@ main::@5: scope:[main] from main::@4
|
||||
if(main::$3) goto main::@7
|
||||
to:main::@8
|
||||
main::@6: scope:[main] from main::@4
|
||||
*VIC_BG_COLOR = $f
|
||||
*VICII_BG_COLOR = $f
|
||||
to:main::@1
|
||||
main::@7: scope:[main] from main::@5 main::@8
|
||||
main::line#3 = phi( main::@5/main::line#2, main::@8/main::line#5 )
|
||||
@ -71,8 +71,8 @@ __start::@return: scope:[__start] from __start::@1
|
||||
SYMBOL TABLE SSA
|
||||
const nomodify byte* SCREEN = (byte*)$400
|
||||
const byte SIZEOF_WORD = 2
|
||||
const nomodify byte* VIC_BG_COLOR = (byte*)$d020
|
||||
const nomodify byte* VIC_RASTER = (byte*)$d012
|
||||
const nomodify byte* VICII_BG_COLOR = (byte*)$d020
|
||||
const nomodify byte* VICII_RASTER = (byte*)$d012
|
||||
void __start()
|
||||
const word* entities[$19] = { fill( $19, 0) }
|
||||
void main()
|
||||
@ -102,17 +102,17 @@ byte* main::line#3
|
||||
byte* main::line#4
|
||||
byte* main::line#5
|
||||
|
||||
Adding number conversion cast (unumber) $ff in main::$0 = *VIC_RASTER != $ff
|
||||
Adding number conversion cast (unumber) 0 in *VIC_BG_COLOR = 0
|
||||
Adding number conversion cast (unumber) $ff in main::$0 = *VICII_RASTER != $ff
|
||||
Adding number conversion cast (unumber) 0 in *VICII_BG_COLOR = 0
|
||||
Adding number conversion cast (unumber) $19 in main::$1 = main::i#2 < $19
|
||||
Adding number conversion cast (unumber) 1 in entities[main::$5] = entities[main::$5] + 1
|
||||
Adding number conversion cast (unumber) $27 in main::$2 = entities[main::$6] > $27
|
||||
Adding number conversion cast (unumber) $f in *VIC_BG_COLOR = $f
|
||||
Adding number conversion cast (unumber) $f in *VICII_BG_COLOR = $f
|
||||
Adding number conversion cast (unumber) $28 in main::line#1 = main::line#3 + $28
|
||||
Adding number conversion cast (unumber) 0 in entities[main::$8] = 0
|
||||
Successful SSA optimization PassNAddNumberTypeConversions
|
||||
Inlining cast *VIC_BG_COLOR = (unumber)0
|
||||
Inlining cast *VIC_BG_COLOR = (unumber)$f
|
||||
Inlining cast *VICII_BG_COLOR = (unumber)0
|
||||
Inlining cast *VICII_BG_COLOR = (unumber)$f
|
||||
Inlining cast entities[main::$8] = (unumber)0
|
||||
Successful SSA optimization Pass2InlineCast
|
||||
Simplifying constant pointer cast (byte*) 53266
|
||||
@ -148,7 +148,7 @@ Identified duplicate assignment right side [15] main::$5 = main::i#2 * SIZEOF_WO
|
||||
Identified duplicate assignment right side [17] main::$6 = main::i#2 * SIZEOF_WORD
|
||||
Successful SSA optimization Pass2DuplicateRValueIdentification
|
||||
Simple Condition main::$10 [2] if(0!=1) goto main::@2
|
||||
Simple Condition main::$0 [4] if(*VIC_RASTER!=$ff) goto main::@2
|
||||
Simple Condition main::$0 [4] if(*VICII_RASTER!=$ff) goto main::@2
|
||||
Simple Condition main::$1 [10] if(main::i#2<$19) goto main::@5
|
||||
Simple Condition main::$3 [18] if(entities[main::$6]<=$27) goto main::@7
|
||||
Successful SSA optimization Pass2ConditionalJumpSimplification
|
||||
@ -219,10 +219,10 @@ main: scope:[main] from
|
||||
asm { sei }
|
||||
to:main::@1
|
||||
main::@1: scope:[main] from main main::@1 main::@5
|
||||
[1] if(*VIC_RASTER!=$ff) goto main::@1
|
||||
[1] if(*VICII_RASTER!=$ff) goto main::@1
|
||||
to:main::@2
|
||||
main::@2: scope:[main] from main::@1
|
||||
[2] *VIC_BG_COLOR = 0
|
||||
[2] *VICII_BG_COLOR = 0
|
||||
to:main::@3
|
||||
main::@3: scope:[main] from main::@2 main::@6
|
||||
[3] main::line#2 = phi( main::@2/SCREEN, main::@6/main::line#1 )
|
||||
@ -230,7 +230,7 @@ main::@3: scope:[main] from main::@2 main::@6
|
||||
[4] if(main::i#2<$19) goto main::@4
|
||||
to:main::@5
|
||||
main::@5: scope:[main] from main::@3
|
||||
[5] *VIC_BG_COLOR = $f
|
||||
[5] *VICII_BG_COLOR = $f
|
||||
to:main::@1
|
||||
main::@4: scope:[main] from main::@3
|
||||
[6] main::$7 = main::i#2 << 1
|
||||
@ -280,9 +280,9 @@ Allocated zp[1]:5 [ main::$7 ]
|
||||
Allocated zp[1]:6 [ main::$9 ]
|
||||
Allocated zp[2]:7 [ main::$11 ]
|
||||
REGISTER UPLIFT POTENTIAL REGISTERS
|
||||
Statement [1] if(*VIC_RASTER!=$ff) goto main::@1 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [2] *VIC_BG_COLOR = 0 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [5] *VIC_BG_COLOR = $f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [1] if(*VICII_RASTER!=$ff) goto main::@1 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [2] *VICII_BG_COLOR = 0 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [5] *VICII_BG_COLOR = $f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [6] main::$7 = main::i#2 << 1 [ main::i#2 main::line#2 main::$7 ] ( [ main::i#2 main::line#2 main::$7 ] { } ) always clobbers reg byte a
|
||||
Removing always clobbered register reg byte a as potential for zp[1]:2 [ main::i#2 main::i#1 ]
|
||||
Statement [7] main::$9 = (byte)entities[main::$7] [ main::i#2 main::line#2 main::$7 main::$9 ] ( [ main::i#2 main::line#2 main::$7 main::$9 ] { } ) always clobbers reg byte a
|
||||
@ -294,9 +294,9 @@ Statement [12] main::$11 = main::line#2 + entities[main::$7] [ main::i#2 main::l
|
||||
Statement [13] *main::$11 = '*' [ main::i#2 main::line#2 ] ( [ main::i#2 main::line#2 ] { } ) always clobbers reg byte a reg byte y
|
||||
Removing always clobbered register reg byte y as potential for zp[1]:2 [ main::i#2 main::i#1 ]
|
||||
Statement [14] main::line#1 = main::line#2 + $28 [ main::i#2 main::line#1 ] ( [ main::i#2 main::line#1 ] { } ) always clobbers reg byte a
|
||||
Statement [1] if(*VIC_RASTER!=$ff) goto main::@1 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [2] *VIC_BG_COLOR = 0 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [5] *VIC_BG_COLOR = $f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [1] if(*VICII_RASTER!=$ff) goto main::@1 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [2] *VICII_BG_COLOR = 0 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [5] *VICII_BG_COLOR = $f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [6] main::$7 = main::i#2 << 1 [ main::i#2 main::line#2 main::$7 ] ( [ main::i#2 main::line#2 main::$7 ] { } ) always clobbers reg byte a
|
||||
Statement [7] main::$9 = (byte)entities[main::$7] [ main::i#2 main::line#2 main::$7 main::$9 ] ( [ main::i#2 main::line#2 main::$7 main::$9 ] { } ) always clobbers reg byte a
|
||||
Statement [8] main::line#2[main::$9] = ' ' [ main::i#2 main::line#2 main::$7 ] ( [ main::i#2 main::line#2 main::$7 ] { } ) always clobbers reg byte a
|
||||
@ -334,8 +334,8 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
.segment Basic
|
||||
:BasicUpstart(main)
|
||||
// Global Constants & labels
|
||||
.label VIC_RASTER = $d012
|
||||
.label VIC_BG_COLOR = $d020
|
||||
.label VICII_RASTER = $d012
|
||||
.label VICII_BG_COLOR = $d020
|
||||
.label SCREEN = $400
|
||||
.segment Code
|
||||
// main
|
||||
@ -350,16 +350,16 @@ main: {
|
||||
// Wait for raster refresh
|
||||
// main::@1
|
||||
__b1:
|
||||
// [1] if(*VIC_RASTER!=$ff) goto main::@1 -- _deref_pbuc1_neq_vbuc2_then_la1
|
||||
// [1] if(*VICII_RASTER!=$ff) goto main::@1 -- _deref_pbuc1_neq_vbuc2_then_la1
|
||||
lda #$ff
|
||||
cmp VIC_RASTER
|
||||
cmp VICII_RASTER
|
||||
bne __b1
|
||||
jmp __b2
|
||||
// main::@2
|
||||
__b2:
|
||||
// [2] *VIC_BG_COLOR = 0 -- _deref_pbuc1=vbuc2
|
||||
// [2] *VICII_BG_COLOR = 0 -- _deref_pbuc1=vbuc2
|
||||
lda #0
|
||||
sta VIC_BG_COLOR
|
||||
sta VICII_BG_COLOR
|
||||
// [3] phi from main::@2 to main::@3 [phi:main::@2->main::@3]
|
||||
__b3_from___b2:
|
||||
// [3] phi main::line#2 = SCREEN [phi:main::@2->main::@3#0] -- pbuz1=pbuc1
|
||||
@ -380,9 +380,9 @@ main: {
|
||||
jmp __b5
|
||||
// main::@5
|
||||
__b5:
|
||||
// [5] *VIC_BG_COLOR = $f -- _deref_pbuc1=vbuc2
|
||||
// [5] *VICII_BG_COLOR = $f -- _deref_pbuc1=vbuc2
|
||||
lda #$f
|
||||
sta VIC_BG_COLOR
|
||||
sta VICII_BG_COLOR
|
||||
jmp __b1
|
||||
// main::@4
|
||||
__b4:
|
||||
@ -474,8 +474,8 @@ Succesful ASM optimization Pass5UnusedLabelElimination
|
||||
|
||||
FINAL SYMBOL TABLE
|
||||
const nomodify byte* SCREEN = (byte*) 1024
|
||||
const nomodify byte* VIC_BG_COLOR = (byte*) 53280
|
||||
const nomodify byte* VIC_RASTER = (byte*) 53266
|
||||
const nomodify byte* VICII_BG_COLOR = (byte*) 53280
|
||||
const nomodify byte* VICII_RASTER = (byte*) 53266
|
||||
const word* entities[$19] = { fill( $19, 0) }
|
||||
void main()
|
||||
byte*~ main::$11 zp[2]:5 202.0
|
||||
@ -510,8 +510,8 @@ Score: 15702
|
||||
.segment Basic
|
||||
:BasicUpstart(main)
|
||||
// Global Constants & labels
|
||||
.label VIC_RASTER = $d012
|
||||
.label VIC_BG_COLOR = $d020
|
||||
.label VICII_RASTER = $d012
|
||||
.label VICII_BG_COLOR = $d020
|
||||
.label SCREEN = $400
|
||||
.segment Code
|
||||
// main
|
||||
@ -526,16 +526,16 @@ main: {
|
||||
// Wait for raster refresh
|
||||
// main::@1
|
||||
__b1:
|
||||
// while(*VIC_RASTER!=0xff)
|
||||
// [1] if(*VIC_RASTER!=$ff) goto main::@1 -- _deref_pbuc1_neq_vbuc2_then_la1
|
||||
// while(*VICII_RASTER!=0xff)
|
||||
// [1] if(*VICII_RASTER!=$ff) goto main::@1 -- _deref_pbuc1_neq_vbuc2_then_la1
|
||||
lda #$ff
|
||||
cmp VIC_RASTER
|
||||
cmp VICII_RASTER
|
||||
bne __b1
|
||||
// main::@2
|
||||
// *VIC_BG_COLOR = 0
|
||||
// [2] *VIC_BG_COLOR = 0 -- _deref_pbuc1=vbuc2
|
||||
// *VICII_BG_COLOR = 0
|
||||
// [2] *VICII_BG_COLOR = 0 -- _deref_pbuc1=vbuc2
|
||||
lda #0
|
||||
sta VIC_BG_COLOR
|
||||
sta VICII_BG_COLOR
|
||||
// [3] phi from main::@2 to main::@3 [phi:main::@2->main::@3]
|
||||
// [3] phi main::line#2 = SCREEN [phi:main::@2->main::@3#0] -- pbuz1=pbuc1
|
||||
lda #<SCREEN
|
||||
@ -553,10 +553,10 @@ main: {
|
||||
cmp #$19
|
||||
bcc __b4
|
||||
// main::@5
|
||||
// *VIC_BG_COLOR = 15
|
||||
// [5] *VIC_BG_COLOR = $f -- _deref_pbuc1=vbuc2
|
||||
// *VICII_BG_COLOR = 15
|
||||
// [5] *VICII_BG_COLOR = $f -- _deref_pbuc1=vbuc2
|
||||
lda #$f
|
||||
sta VIC_BG_COLOR
|
||||
sta VICII_BG_COLOR
|
||||
jmp __b1
|
||||
// main::@4
|
||||
__b4:
|
||||
|
@ -1,6 +1,6 @@
|
||||
const nomodify byte* SCREEN = (byte*) 1024
|
||||
const nomodify byte* VIC_BG_COLOR = (byte*) 53280
|
||||
const nomodify byte* VIC_RASTER = (byte*) 53266
|
||||
const nomodify byte* VICII_BG_COLOR = (byte*) 53280
|
||||
const nomodify byte* VICII_RASTER = (byte*) 53266
|
||||
const word* entities[$19] = { fill( $19, 0) }
|
||||
void main()
|
||||
byte*~ main::$11 zp[2]:5 202.0
|
||||
|
@ -9,8 +9,8 @@
|
||||
:BasicUpstart(main)
|
||||
.const OFFSET_STRUCT_ENTITY_X_VEL = 1
|
||||
.const OFFSET_STRUCT_ENTITY_SYMBOL = 2
|
||||
.label VIC_RASTER = $d012
|
||||
.label VIC_BG_COLOR = $d020
|
||||
.label VICII_RASTER = $d012
|
||||
.label VICII_BG_COLOR = $d020
|
||||
.label SCREEN = $400
|
||||
.segment Code
|
||||
main: {
|
||||
@ -30,13 +30,13 @@ main: {
|
||||
bcc __b2
|
||||
// Wait for raster refresh
|
||||
__b3:
|
||||
// while(*VIC_RASTER!=0xff)
|
||||
// while(*VICII_RASTER!=0xff)
|
||||
lda #$ff
|
||||
cmp VIC_RASTER
|
||||
cmp VICII_RASTER
|
||||
bne __b3
|
||||
// *VIC_BG_COLOR = 0
|
||||
// *VICII_BG_COLOR = 0
|
||||
lda #0
|
||||
sta VIC_BG_COLOR
|
||||
sta VICII_BG_COLOR
|
||||
lda #<SCREEN
|
||||
sta.z line
|
||||
lda #>SCREEN
|
||||
@ -48,9 +48,9 @@ main: {
|
||||
lda.z i1
|
||||
cmp #$19
|
||||
bcc __b6
|
||||
// *VIC_BG_COLOR = 15
|
||||
// *VICII_BG_COLOR = 15
|
||||
lda #$f
|
||||
sta VIC_BG_COLOR
|
||||
sta VICII_BG_COLOR
|
||||
jmp __b3
|
||||
__b6:
|
||||
// line[entities[i].x_pos] = ' '
|
||||
|
@ -9,10 +9,10 @@ main::@1: scope:[main] from main main::@2
|
||||
[2] if(main::i#2<$19) goto main::@2
|
||||
to:main::@3
|
||||
main::@3: scope:[main] from main::@1 main::@3 main::@7
|
||||
[3] if(*VIC_RASTER!=$ff) goto main::@3
|
||||
[3] if(*VICII_RASTER!=$ff) goto main::@3
|
||||
to:main::@4
|
||||
main::@4: scope:[main] from main::@3
|
||||
[4] *VIC_BG_COLOR = 0
|
||||
[4] *VICII_BG_COLOR = 0
|
||||
to:main::@5
|
||||
main::@5: scope:[main] from main::@4 main::@8
|
||||
[5] main::line#2 = phi( main::@4/SCREEN, main::@8/main::line#1 )
|
||||
@ -20,7 +20,7 @@ main::@5: scope:[main] from main::@4 main::@8
|
||||
[6] if(main::i1#2<$19) goto main::@6
|
||||
to:main::@7
|
||||
main::@7: scope:[main] from main::@5
|
||||
[7] *VIC_BG_COLOR = $f
|
||||
[7] *VICII_BG_COLOR = $f
|
||||
to:main::@3
|
||||
main::@6: scope:[main] from main::@5
|
||||
[8] main::$25 = main::i1#2 << 1
|
||||
|
@ -31,11 +31,11 @@ main::@3: scope:[main] from main::@1 main::@8
|
||||
if(main::$20) goto main::@4
|
||||
to:main::@return
|
||||
main::@4: scope:[main] from main::@3 main::@4
|
||||
main::$2 = *VIC_RASTER != $ff
|
||||
main::$2 = *VICII_RASTER != $ff
|
||||
if(main::$2) goto main::@4
|
||||
to:main::@5
|
||||
main::@5: scope:[main] from main::@4
|
||||
*VIC_BG_COLOR = 0
|
||||
*VICII_BG_COLOR = 0
|
||||
main::line#0 = SCREEN
|
||||
main::i1#0 = 0
|
||||
to:main::@6
|
||||
@ -61,7 +61,7 @@ main::@7: scope:[main] from main::@6
|
||||
if(main::$7) goto main::@9
|
||||
to:main::@10
|
||||
main::@8: scope:[main] from main::@6
|
||||
*VIC_BG_COLOR = $f
|
||||
*VICII_BG_COLOR = $f
|
||||
to:main::@3
|
||||
main::@9: scope:[main] from main::@10 main::@7
|
||||
main::line#3 = phi( main::@10/main::line#5, main::@7/main::line#2 )
|
||||
@ -101,8 +101,8 @@ const byte OFFSET_STRUCT_ENTITY_X_POS = 0
|
||||
const byte OFFSET_STRUCT_ENTITY_X_VEL = 1
|
||||
const nomodify byte* SCREEN = (byte*)$400
|
||||
const byte SIZEOF_STRUCT_ENTITY = 3
|
||||
const nomodify byte* VIC_BG_COLOR = (byte*)$d020
|
||||
const nomodify byte* VIC_RASTER = (byte*)$d012
|
||||
const nomodify byte* VICII_BG_COLOR = (byte*)$d020
|
||||
const nomodify byte* VICII_RASTER = (byte*)$d012
|
||||
void __start()
|
||||
const struct Entity* entities[$19] = { fill( $19, 0) }
|
||||
void main()
|
||||
@ -153,16 +153,16 @@ signed byte main::v#2
|
||||
signed byte main::v#3
|
||||
|
||||
Adding number conversion cast (unumber) $19 in main::$0 = main::i#2 < $19
|
||||
Adding number conversion cast (unumber) $ff in main::$2 = *VIC_RASTER != $ff
|
||||
Adding number conversion cast (unumber) 0 in *VIC_BG_COLOR = 0
|
||||
Adding number conversion cast (unumber) $ff in main::$2 = *VICII_RASTER != $ff
|
||||
Adding number conversion cast (unumber) 0 in *VICII_BG_COLOR = 0
|
||||
Adding number conversion cast (unumber) $19 in main::$3 = main::i1#2 < $19
|
||||
Adding number conversion cast (snumber) 0 in main::$4 = ((signed byte*)entities+OFFSET_STRUCT_ENTITY_X_POS)[main::$14] < 0
|
||||
Adding number conversion cast (snumber) $27 in main::$5 = ((signed byte*)entities+OFFSET_STRUCT_ENTITY_X_POS)[main::$15] > $27
|
||||
Adding number conversion cast (unumber) $f in *VIC_BG_COLOR = $f
|
||||
Adding number conversion cast (unumber) $f in *VICII_BG_COLOR = $f
|
||||
Adding number conversion cast (unumber) $28 in main::line#1 = main::line#3 + $28
|
||||
Successful SSA optimization PassNAddNumberTypeConversions
|
||||
Inlining cast *VIC_BG_COLOR = (unumber)0
|
||||
Inlining cast *VIC_BG_COLOR = (unumber)$f
|
||||
Inlining cast *VICII_BG_COLOR = (unumber)0
|
||||
Inlining cast *VICII_BG_COLOR = (unumber)$f
|
||||
Successful SSA optimization Pass2InlineCast
|
||||
Simplifying constant pointer cast (byte*) 53266
|
||||
Simplifying constant pointer cast (byte*) 53280
|
||||
@ -204,7 +204,7 @@ Identified duplicate assignment right side [49] main::$19 = main::i1#2 * SIZEOF_
|
||||
Successful SSA optimization Pass2DuplicateRValueIdentification
|
||||
Simple Condition main::$0 [5] if(main::i#2<$19) goto main::@2
|
||||
Simple Condition main::$20 [15] if(0!=1) goto main::@4
|
||||
Simple Condition main::$2 [17] if(*VIC_RASTER!=$ff) goto main::@4
|
||||
Simple Condition main::$2 [17] if(*VICII_RASTER!=$ff) goto main::@4
|
||||
Simple Condition main::$3 [23] if(main::i1#2<$19) goto main::@7
|
||||
Successful SSA optimization Pass2ConditionalJumpSimplification
|
||||
Rewriting ! if()-condition to reversed if() [33] main::$7 = ! main::$6
|
||||
@ -318,10 +318,10 @@ main::@1: scope:[main] from main main::@2
|
||||
[2] if(main::i#2<$19) goto main::@2
|
||||
to:main::@3
|
||||
main::@3: scope:[main] from main::@1 main::@3 main::@7
|
||||
[3] if(*VIC_RASTER!=$ff) goto main::@3
|
||||
[3] if(*VICII_RASTER!=$ff) goto main::@3
|
||||
to:main::@4
|
||||
main::@4: scope:[main] from main::@3
|
||||
[4] *VIC_BG_COLOR = 0
|
||||
[4] *VICII_BG_COLOR = 0
|
||||
to:main::@5
|
||||
main::@5: scope:[main] from main::@4 main::@8
|
||||
[5] main::line#2 = phi( main::@4/SCREEN, main::@8/main::line#1 )
|
||||
@ -329,7 +329,7 @@ main::@5: scope:[main] from main::@4 main::@8
|
||||
[6] if(main::i1#2<$19) goto main::@6
|
||||
to:main::@7
|
||||
main::@7: scope:[main] from main::@5
|
||||
[7] *VIC_BG_COLOR = $f
|
||||
[7] *VICII_BG_COLOR = $f
|
||||
to:main::@3
|
||||
main::@6: scope:[main] from main::@5
|
||||
[8] main::$25 = main::i1#2 << 1
|
||||
@ -412,9 +412,9 @@ Allocated zp[1]:9 [ main::$8 ]
|
||||
Allocated zp[1]:10 [ main::$21 ]
|
||||
Allocated zp[1]:11 [ main::$10 ]
|
||||
REGISTER UPLIFT POTENTIAL REGISTERS
|
||||
Statement [3] if(*VIC_RASTER!=$ff) goto main::@3 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [4] *VIC_BG_COLOR = 0 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [7] *VIC_BG_COLOR = $f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [3] if(*VICII_RASTER!=$ff) goto main::@3 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [4] *VICII_BG_COLOR = 0 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [7] *VICII_BG_COLOR = $f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [8] main::$25 = main::i1#2 << 1 [ main::i1#2 main::line#2 main::$25 ] ( [ main::i1#2 main::line#2 main::$25 ] { } ) always clobbers reg byte a
|
||||
Removing always clobbered register reg byte a as potential for zp[1]:4 [ main::i1#2 main::i1#1 ]
|
||||
Statement [9] main::$16 = main::$25 + main::i1#2 [ main::i1#2 main::line#2 main::$16 ] ( [ main::i1#2 main::line#2 main::$16 ] { } ) always clobbers reg byte a
|
||||
@ -438,9 +438,9 @@ Removing always clobbered register reg byte a as potential for zp[1]:11 [ main::
|
||||
Statement [23] ((signed byte*)entities+OFFSET_STRUCT_ENTITY_X_VEL)[main::$10] = main::v#2 [ main::i#2 main::v#2 main::$10 ] ( [ main::i#2 main::v#2 main::$10 ] { } ) always clobbers reg byte a
|
||||
Statement [24] ((byte*)entities+OFFSET_STRUCT_ENTITY_SYMBOL)[main::$10] = main::i#2 [ main::i#2 main::v#2 ] ( [ main::i#2 main::v#2 ] { } ) always clobbers reg byte a
|
||||
Statement [25] main::v#1 = - main::v#2 [ main::i#2 main::v#1 ] ( [ main::i#2 main::v#1 ] { } ) always clobbers reg byte a
|
||||
Statement [3] if(*VIC_RASTER!=$ff) goto main::@3 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [4] *VIC_BG_COLOR = 0 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [7] *VIC_BG_COLOR = $f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [3] if(*VICII_RASTER!=$ff) goto main::@3 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [4] *VICII_BG_COLOR = 0 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [7] *VICII_BG_COLOR = $f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [8] main::$25 = main::i1#2 << 1 [ main::i1#2 main::line#2 main::$25 ] ( [ main::i1#2 main::line#2 main::$25 ] { } ) always clobbers reg byte a
|
||||
Statement [9] main::$16 = main::$25 + main::i1#2 [ main::i1#2 main::line#2 main::$16 ] ( [ main::i1#2 main::line#2 main::$16 ] { } ) always clobbers reg byte a
|
||||
Statement [10] main::line#2[((signed byte*)entities)[main::$16]] = ' ' [ main::i1#2 main::line#2 main::$16 ] ( [ main::i1#2 main::line#2 main::$16 ] { } ) always clobbers reg byte a reg byte y
|
||||
@ -505,8 +505,8 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
// Global Constants & labels
|
||||
.const OFFSET_STRUCT_ENTITY_X_VEL = 1
|
||||
.const OFFSET_STRUCT_ENTITY_SYMBOL = 2
|
||||
.label VIC_RASTER = $d012
|
||||
.label VIC_BG_COLOR = $d020
|
||||
.label VICII_RASTER = $d012
|
||||
.label VICII_BG_COLOR = $d020
|
||||
.label SCREEN = $400
|
||||
.segment Code
|
||||
// main
|
||||
@ -535,16 +535,16 @@ main: {
|
||||
// Wait for raster refresh
|
||||
// main::@3
|
||||
__b3:
|
||||
// [3] if(*VIC_RASTER!=$ff) goto main::@3 -- _deref_pbuc1_neq_vbuc2_then_la1
|
||||
// [3] if(*VICII_RASTER!=$ff) goto main::@3 -- _deref_pbuc1_neq_vbuc2_then_la1
|
||||
lda #$ff
|
||||
cmp VIC_RASTER
|
||||
cmp VICII_RASTER
|
||||
bne __b3
|
||||
jmp __b4
|
||||
// main::@4
|
||||
__b4:
|
||||
// [4] *VIC_BG_COLOR = 0 -- _deref_pbuc1=vbuc2
|
||||
// [4] *VICII_BG_COLOR = 0 -- _deref_pbuc1=vbuc2
|
||||
lda #0
|
||||
sta VIC_BG_COLOR
|
||||
sta VICII_BG_COLOR
|
||||
// [5] phi from main::@4 to main::@5 [phi:main::@4->main::@5]
|
||||
__b5_from___b4:
|
||||
// [5] phi main::line#2 = SCREEN [phi:main::@4->main::@5#0] -- pbuz1=pbuc1
|
||||
@ -565,9 +565,9 @@ main: {
|
||||
jmp __b7
|
||||
// main::@7
|
||||
__b7:
|
||||
// [7] *VIC_BG_COLOR = $f -- _deref_pbuc1=vbuc2
|
||||
// [7] *VICII_BG_COLOR = $f -- _deref_pbuc1=vbuc2
|
||||
lda #$f
|
||||
sta VIC_BG_COLOR
|
||||
sta VICII_BG_COLOR
|
||||
jmp __b3
|
||||
// main::@6
|
||||
__b6:
|
||||
@ -703,8 +703,8 @@ FINAL SYMBOL TABLE
|
||||
const byte OFFSET_STRUCT_ENTITY_SYMBOL = 2
|
||||
const byte OFFSET_STRUCT_ENTITY_X_VEL = 1
|
||||
const nomodify byte* SCREEN = (byte*) 1024
|
||||
const nomodify byte* VIC_BG_COLOR = (byte*) 53280
|
||||
const nomodify byte* VIC_RASTER = (byte*) 53266
|
||||
const nomodify byte* VICII_BG_COLOR = (byte*) 53280
|
||||
const nomodify byte* VICII_RASTER = (byte*) 53266
|
||||
const struct Entity* entities[$19] = { fill( $19, 0) }
|
||||
void main()
|
||||
byte~ main::$10 reg byte y 14.666666666666666
|
||||
@ -753,8 +753,8 @@ Score: 17597
|
||||
// Global Constants & labels
|
||||
.const OFFSET_STRUCT_ENTITY_X_VEL = 1
|
||||
.const OFFSET_STRUCT_ENTITY_SYMBOL = 2
|
||||
.label VIC_RASTER = $d012
|
||||
.label VIC_BG_COLOR = $d020
|
||||
.label VICII_RASTER = $d012
|
||||
.label VICII_BG_COLOR = $d020
|
||||
.label SCREEN = $400
|
||||
.segment Code
|
||||
// main
|
||||
@ -782,16 +782,16 @@ main: {
|
||||
// Wait for raster refresh
|
||||
// main::@3
|
||||
__b3:
|
||||
// while(*VIC_RASTER!=0xff)
|
||||
// [3] if(*VIC_RASTER!=$ff) goto main::@3 -- _deref_pbuc1_neq_vbuc2_then_la1
|
||||
// while(*VICII_RASTER!=0xff)
|
||||
// [3] if(*VICII_RASTER!=$ff) goto main::@3 -- _deref_pbuc1_neq_vbuc2_then_la1
|
||||
lda #$ff
|
||||
cmp VIC_RASTER
|
||||
cmp VICII_RASTER
|
||||
bne __b3
|
||||
// main::@4
|
||||
// *VIC_BG_COLOR = 0
|
||||
// [4] *VIC_BG_COLOR = 0 -- _deref_pbuc1=vbuc2
|
||||
// *VICII_BG_COLOR = 0
|
||||
// [4] *VICII_BG_COLOR = 0 -- _deref_pbuc1=vbuc2
|
||||
lda #0
|
||||
sta VIC_BG_COLOR
|
||||
sta VICII_BG_COLOR
|
||||
// [5] phi from main::@4 to main::@5 [phi:main::@4->main::@5]
|
||||
// [5] phi main::line#2 = SCREEN [phi:main::@4->main::@5#0] -- pbuz1=pbuc1
|
||||
lda #<SCREEN
|
||||
@ -809,10 +809,10 @@ main: {
|
||||
cmp #$19
|
||||
bcc __b6
|
||||
// main::@7
|
||||
// *VIC_BG_COLOR = 15
|
||||
// [7] *VIC_BG_COLOR = $f -- _deref_pbuc1=vbuc2
|
||||
// *VICII_BG_COLOR = 15
|
||||
// [7] *VICII_BG_COLOR = $f -- _deref_pbuc1=vbuc2
|
||||
lda #$f
|
||||
sta VIC_BG_COLOR
|
||||
sta VICII_BG_COLOR
|
||||
jmp __b3
|
||||
// main::@6
|
||||
__b6:
|
||||
|
@ -1,8 +1,8 @@
|
||||
const byte OFFSET_STRUCT_ENTITY_SYMBOL = 2
|
||||
const byte OFFSET_STRUCT_ENTITY_X_VEL = 1
|
||||
const nomodify byte* SCREEN = (byte*) 1024
|
||||
const nomodify byte* VIC_BG_COLOR = (byte*) 53280
|
||||
const nomodify byte* VIC_RASTER = (byte*) 53266
|
||||
const nomodify byte* VICII_BG_COLOR = (byte*) 53280
|
||||
const nomodify byte* VICII_RASTER = (byte*) 53266
|
||||
const struct Entity* entities[$19] = { fill( $19, 0) }
|
||||
void main()
|
||||
byte~ main::$10 reg byte y 14.666666666666666
|
||||
|
@ -17,7 +17,7 @@
|
||||
.const PROCPORT_RAM_IO = $35
|
||||
.label HARDWARE_IRQ = $fffe
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -61,11 +61,11 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// *VIC_CONTROL |=$80
|
||||
// *VICII_CONTROL |=$80
|
||||
// Set raster line to $100
|
||||
lda #$80
|
||||
ora VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
ora VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// *RASTER = $00
|
||||
lda #0
|
||||
sta RASTER
|
||||
|
@ -15,7 +15,7 @@ main: scope:[main] from
|
||||
[5] *PROCPORT_DDR = PROCPORT_DDR_MEMORY_MASK
|
||||
[6] *PROCPORT = PROCPORT_RAM_IO
|
||||
[7] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
[8] *VIC_CONTROL = *VIC_CONTROL | $80
|
||||
[8] *VICII_CONTROL = *VICII_CONTROL | $80
|
||||
[9] *RASTER = 0
|
||||
[10] *IRQ_ENABLE = IRQ_RASTER
|
||||
[11] *HARDWARE_IRQ = &irq
|
||||
|
@ -8,7 +8,7 @@ main: scope:[main] from __start
|
||||
*PROCPORT_DDR = PROCPORT_DDR_MEMORY_MASK
|
||||
*PROCPORT = PROCPORT_RAM_IO
|
||||
*CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
*VIC_CONTROL = *VIC_CONTROL | $80
|
||||
*VICII_CONTROL = *VICII_CONTROL | $80
|
||||
*RASTER = 0
|
||||
*IRQ_ENABLE = IRQ_RASTER
|
||||
*HARDWARE_IRQ = &irq
|
||||
@ -59,13 +59,13 @@ const nomodify byte* PROCPORT_DDR = (byte*)0
|
||||
const nomodify byte PROCPORT_DDR_MEMORY_MASK = 7
|
||||
const nomodify byte PROCPORT_RAM_IO = $35
|
||||
const nomodify byte* RASTER = (byte*)$d012
|
||||
const nomodify byte* VIC_CONTROL = (byte*)$d011
|
||||
const nomodify byte* VICII_CONTROL = (byte*)$d011
|
||||
const nomodify byte WHITE = 1
|
||||
void __start()
|
||||
__interrupt(hardware_clobber) void irq()
|
||||
void main()
|
||||
|
||||
Adding number conversion cast (unumber) $80 in *VIC_CONTROL = *VIC_CONTROL | $80
|
||||
Adding number conversion cast (unumber) $80 in *VICII_CONTROL = *VICII_CONTROL | $80
|
||||
Adding number conversion cast (unumber) 0 in *RASTER = 0
|
||||
Successful SSA optimization PassNAddNumberTypeConversions
|
||||
Inlining cast *RASTER = (unumber)0
|
||||
@ -121,7 +121,7 @@ main: scope:[main] from
|
||||
[5] *PROCPORT_DDR = PROCPORT_DDR_MEMORY_MASK
|
||||
[6] *PROCPORT = PROCPORT_RAM_IO
|
||||
[7] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
[8] *VIC_CONTROL = *VIC_CONTROL | $80
|
||||
[8] *VICII_CONTROL = *VICII_CONTROL | $80
|
||||
[9] *RASTER = 0
|
||||
[10] *IRQ_ENABLE = IRQ_RASTER
|
||||
[11] *HARDWARE_IRQ = &irq
|
||||
@ -146,7 +146,7 @@ Statement [3] return [ ] ( [ ] { } ) always clobbers reg byte a reg byte x re
|
||||
Statement [5] *PROCPORT_DDR = PROCPORT_DDR_MEMORY_MASK [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [6] *PROCPORT = PROCPORT_RAM_IO [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [7] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [8] *VIC_CONTROL = *VIC_CONTROL | $80 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [8] *VICII_CONTROL = *VICII_CONTROL | $80 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [9] *RASTER = 0 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [10] *IRQ_ENABLE = IRQ_RASTER [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [11] *HARDWARE_IRQ = &irq [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
@ -184,7 +184,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
.const PROCPORT_RAM_IO = $35
|
||||
.label HARDWARE_IRQ = $fffe
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -235,11 +235,11 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// [8] *VIC_CONTROL = *VIC_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// [8] *VICII_CONTROL = *VICII_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// Set raster line to $100
|
||||
lda #$80
|
||||
ora VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
ora VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// [9] *RASTER = 0 -- _deref_pbuc1=vbuc2
|
||||
lda #0
|
||||
sta RASTER
|
||||
@ -286,7 +286,7 @@ const nomodify byte* PROCPORT_DDR = (byte*) 0
|
||||
const nomodify byte PROCPORT_DDR_MEMORY_MASK = 7
|
||||
const nomodify byte PROCPORT_RAM_IO = $35
|
||||
const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* VIC_CONTROL = (byte*) 53265
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
const nomodify byte WHITE = 1
|
||||
__interrupt(hardware_clobber) void irq()
|
||||
void main()
|
||||
@ -318,7 +318,7 @@ Score: 284
|
||||
.const PROCPORT_RAM_IO = $35
|
||||
.label HARDWARE_IRQ = $fffe
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -375,12 +375,12 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// *VIC_CONTROL |=$80
|
||||
// [8] *VIC_CONTROL = *VIC_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// *VICII_CONTROL |=$80
|
||||
// [8] *VICII_CONTROL = *VICII_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// Set raster line to $100
|
||||
lda #$80
|
||||
ora VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
ora VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// *RASTER = $00
|
||||
// [9] *RASTER = 0 -- _deref_pbuc1=vbuc2
|
||||
lda #0
|
||||
|
@ -12,7 +12,7 @@ const nomodify byte* PROCPORT_DDR = (byte*) 0
|
||||
const nomodify byte PROCPORT_DDR_MEMORY_MASK = 7
|
||||
const nomodify byte PROCPORT_RAM_IO = $35
|
||||
const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* VIC_CONTROL = (byte*) 53265
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
const nomodify byte WHITE = 1
|
||||
__interrupt(hardware_clobber) void irq()
|
||||
void main()
|
||||
|
@ -17,7 +17,7 @@
|
||||
.const PROCPORT_RAM_IO = $35
|
||||
.label HARDWARE_IRQ = $fffe
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -67,11 +67,11 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// *VIC_CONTROL |=$80
|
||||
// *VICII_CONTROL |=$80
|
||||
// Set raster line to $100
|
||||
lda #$80
|
||||
ora VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
ora VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// *RASTER = $00
|
||||
lda #0
|
||||
sta RASTER
|
||||
|
@ -15,7 +15,7 @@ main: scope:[main] from
|
||||
[5] *PROCPORT_DDR = PROCPORT_DDR_MEMORY_MASK
|
||||
[6] *PROCPORT = PROCPORT_RAM_IO
|
||||
[7] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
[8] *VIC_CONTROL = *VIC_CONTROL | $80
|
||||
[8] *VICII_CONTROL = *VICII_CONTROL | $80
|
||||
[9] *RASTER = 0
|
||||
[10] *IRQ_ENABLE = IRQ_RASTER
|
||||
[11] *HARDWARE_IRQ = &irq
|
||||
|
@ -8,7 +8,7 @@ main: scope:[main] from __start
|
||||
*PROCPORT_DDR = PROCPORT_DDR_MEMORY_MASK
|
||||
*PROCPORT = PROCPORT_RAM_IO
|
||||
*CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
*VIC_CONTROL = *VIC_CONTROL | $80
|
||||
*VICII_CONTROL = *VICII_CONTROL | $80
|
||||
*RASTER = 0
|
||||
*IRQ_ENABLE = IRQ_RASTER
|
||||
*HARDWARE_IRQ = &irq
|
||||
@ -59,13 +59,13 @@ const nomodify byte* PROCPORT_DDR = (byte*)0
|
||||
const nomodify byte PROCPORT_DDR_MEMORY_MASK = 7
|
||||
const nomodify byte PROCPORT_RAM_IO = $35
|
||||
const nomodify byte* RASTER = (byte*)$d012
|
||||
const nomodify byte* VIC_CONTROL = (byte*)$d011
|
||||
const nomodify byte* VICII_CONTROL = (byte*)$d011
|
||||
const nomodify byte WHITE = 1
|
||||
void __start()
|
||||
__interrupt(hardware_all) void irq()
|
||||
void main()
|
||||
|
||||
Adding number conversion cast (unumber) $80 in *VIC_CONTROL = *VIC_CONTROL | $80
|
||||
Adding number conversion cast (unumber) $80 in *VICII_CONTROL = *VICII_CONTROL | $80
|
||||
Adding number conversion cast (unumber) 0 in *RASTER = 0
|
||||
Successful SSA optimization PassNAddNumberTypeConversions
|
||||
Inlining cast *RASTER = (unumber)0
|
||||
@ -121,7 +121,7 @@ main: scope:[main] from
|
||||
[5] *PROCPORT_DDR = PROCPORT_DDR_MEMORY_MASK
|
||||
[6] *PROCPORT = PROCPORT_RAM_IO
|
||||
[7] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
[8] *VIC_CONTROL = *VIC_CONTROL | $80
|
||||
[8] *VICII_CONTROL = *VICII_CONTROL | $80
|
||||
[9] *RASTER = 0
|
||||
[10] *IRQ_ENABLE = IRQ_RASTER
|
||||
[11] *HARDWARE_IRQ = &irq
|
||||
@ -146,7 +146,7 @@ Statement [3] return [ ] ( [ ] { } ) always clobbers reg byte a reg byte x re
|
||||
Statement [5] *PROCPORT_DDR = PROCPORT_DDR_MEMORY_MASK [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [6] *PROCPORT = PROCPORT_RAM_IO [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [7] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [8] *VIC_CONTROL = *VIC_CONTROL | $80 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [8] *VICII_CONTROL = *VICII_CONTROL | $80 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [9] *RASTER = 0 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [10] *IRQ_ENABLE = IRQ_RASTER [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [11] *HARDWARE_IRQ = &irq [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
@ -183,7 +183,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
.const PROCPORT_RAM_IO = $35
|
||||
.label HARDWARE_IRQ = $fffe
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -240,11 +240,11 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// [8] *VIC_CONTROL = *VIC_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// [8] *VICII_CONTROL = *VICII_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// Set raster line to $100
|
||||
lda #$80
|
||||
ora VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
ora VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// [9] *RASTER = 0 -- _deref_pbuc1=vbuc2
|
||||
lda #0
|
||||
sta RASTER
|
||||
@ -291,7 +291,7 @@ const nomodify byte* PROCPORT_DDR = (byte*) 0
|
||||
const nomodify byte PROCPORT_DDR_MEMORY_MASK = 7
|
||||
const nomodify byte PROCPORT_RAM_IO = $35
|
||||
const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* VIC_CONTROL = (byte*) 53265
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
const nomodify byte WHITE = 1
|
||||
__interrupt(hardware_all) void irq()
|
||||
void main()
|
||||
@ -323,7 +323,7 @@ Score: 404
|
||||
.const PROCPORT_RAM_IO = $35
|
||||
.label HARDWARE_IRQ = $fffe
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -386,12 +386,12 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// *VIC_CONTROL |=$80
|
||||
// [8] *VIC_CONTROL = *VIC_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// *VICII_CONTROL |=$80
|
||||
// [8] *VICII_CONTROL = *VICII_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// Set raster line to $100
|
||||
lda #$80
|
||||
ora VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
ora VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// *RASTER = $00
|
||||
// [9] *RASTER = 0 -- _deref_pbuc1=vbuc2
|
||||
lda #0
|
||||
|
@ -12,7 +12,7 @@ const nomodify byte* PROCPORT_DDR = (byte*) 0
|
||||
const nomodify byte PROCPORT_DDR_MEMORY_MASK = 7
|
||||
const nomodify byte PROCPORT_RAM_IO = $35
|
||||
const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* VIC_CONTROL = (byte*) 53265
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
const nomodify byte WHITE = 1
|
||||
__interrupt(hardware_all) void irq()
|
||||
void main()
|
||||
|
@ -13,7 +13,7 @@
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
.label KERNEL_IRQ = $314
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -41,11 +41,11 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// *VIC_CONTROL |=$80
|
||||
// *VICII_CONTROL |=$80
|
||||
// Set raster line to $100
|
||||
lda #$80
|
||||
ora VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
ora VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// *RASTER = $00
|
||||
lda #0
|
||||
sta RASTER
|
||||
|
@ -13,7 +13,7 @@ void main()
|
||||
main: scope:[main] from
|
||||
asm { sei }
|
||||
[5] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
[6] *VIC_CONTROL = *VIC_CONTROL | $80
|
||||
[6] *VICII_CONTROL = *VICII_CONTROL | $80
|
||||
[7] *RASTER = 0
|
||||
[8] *IRQ_ENABLE = IRQ_RASTER
|
||||
[9] *KERNEL_IRQ = &irq
|
||||
|
@ -6,7 +6,7 @@ void main()
|
||||
main: scope:[main] from __start
|
||||
asm { sei }
|
||||
*CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
*VIC_CONTROL = *VIC_CONTROL | $80
|
||||
*VICII_CONTROL = *VICII_CONTROL | $80
|
||||
*RASTER = 0
|
||||
*IRQ_ENABLE = IRQ_RASTER
|
||||
*KERNEL_IRQ = &irq
|
||||
@ -46,13 +46,13 @@ const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte* IRQ_STATUS = (byte*)$d019
|
||||
const nomodify void()** KERNEL_IRQ = (void()**)$314
|
||||
const nomodify byte* RASTER = (byte*)$d012
|
||||
const nomodify byte* VIC_CONTROL = (byte*)$d011
|
||||
const nomodify byte* VICII_CONTROL = (byte*)$d011
|
||||
const nomodify byte WHITE = 1
|
||||
void __start()
|
||||
__interrupt(rom_sys_c64) void irq()
|
||||
void main()
|
||||
|
||||
Adding number conversion cast (unumber) $80 in *VIC_CONTROL = *VIC_CONTROL | $80
|
||||
Adding number conversion cast (unumber) $80 in *VICII_CONTROL = *VICII_CONTROL | $80
|
||||
Adding number conversion cast (unumber) 0 in *RASTER = 0
|
||||
Successful SSA optimization PassNAddNumberTypeConversions
|
||||
Inlining cast *RASTER = (unumber)0
|
||||
@ -96,7 +96,7 @@ void main()
|
||||
main: scope:[main] from
|
||||
asm { sei }
|
||||
[5] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
[6] *VIC_CONTROL = *VIC_CONTROL | $80
|
||||
[6] *VICII_CONTROL = *VICII_CONTROL | $80
|
||||
[7] *RASTER = 0
|
||||
[8] *IRQ_ENABLE = IRQ_RASTER
|
||||
[9] *KERNEL_IRQ = &irq
|
||||
@ -118,7 +118,7 @@ Statement [0] *BG_COLOR = WHITE [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [1] *BG_COLOR = BLACK [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [2] *IRQ_STATUS = IRQ_RASTER [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [5] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [6] *VIC_CONTROL = *VIC_CONTROL | $80 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [6] *VICII_CONTROL = *VICII_CONTROL | $80 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [7] *RASTER = 0 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [8] *IRQ_ENABLE = IRQ_RASTER [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [9] *KERNEL_IRQ = &irq [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
@ -151,7 +151,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
.label KERNEL_IRQ = $314
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -186,11 +186,11 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// [6] *VIC_CONTROL = *VIC_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// [6] *VICII_CONTROL = *VICII_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// Set raster line to $100
|
||||
lda #$80
|
||||
ora VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
ora VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// [7] *RASTER = 0 -- _deref_pbuc1=vbuc2
|
||||
lda #0
|
||||
sta RASTER
|
||||
@ -232,7 +232,7 @@ const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte* IRQ_STATUS = (byte*) 53273
|
||||
const nomodify void()** KERNEL_IRQ = (void()**) 788
|
||||
const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* VIC_CONTROL = (byte*) 53265
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
const nomodify byte WHITE = 1
|
||||
__interrupt(rom_sys_c64) void irq()
|
||||
void main()
|
||||
@ -260,7 +260,7 @@ Score: 98
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
.label KERNEL_IRQ = $314
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -299,12 +299,12 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// *VIC_CONTROL |=$80
|
||||
// [6] *VIC_CONTROL = *VIC_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// *VICII_CONTROL |=$80
|
||||
// [6] *VICII_CONTROL = *VICII_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// Set raster line to $100
|
||||
lda #$80
|
||||
ora VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
ora VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// *RASTER = $00
|
||||
// [7] *RASTER = 0 -- _deref_pbuc1=vbuc2
|
||||
lda #0
|
||||
|
@ -7,7 +7,7 @@ const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte* IRQ_STATUS = (byte*) 53273
|
||||
const nomodify void()** KERNEL_IRQ = (void()**) 788
|
||||
const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* VIC_CONTROL = (byte*) 53265
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
const nomodify byte WHITE = 1
|
||||
__interrupt(rom_sys_c64) void irq()
|
||||
void main()
|
||||
|
@ -11,7 +11,7 @@
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
.label KERNEL_IRQ = $314
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -75,11 +75,11 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// *VIC_CONTROL &=$7f
|
||||
// *VICII_CONTROL &=$7f
|
||||
// Set raster line to $0fd
|
||||
lda #$7f
|
||||
and VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
and VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// *RASTER = $fd
|
||||
lda #$fd
|
||||
sta RASTER
|
||||
|
@ -40,7 +40,7 @@ void main()
|
||||
main: scope:[main] from
|
||||
asm { sei }
|
||||
[18] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
[19] *VIC_CONTROL = *VIC_CONTROL & $7f
|
||||
[19] *VICII_CONTROL = *VICII_CONTROL & $7f
|
||||
[20] *RASTER = $fd
|
||||
[21] *IRQ_ENABLE = IRQ_RASTER
|
||||
[22] *KERNEL_IRQ = &irq
|
||||
|
@ -6,7 +6,7 @@ void main()
|
||||
main: scope:[main] from __start
|
||||
asm { sei }
|
||||
*CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
*VIC_CONTROL = *VIC_CONTROL & $7f
|
||||
*VICII_CONTROL = *VICII_CONTROL & $7f
|
||||
*RASTER = $fd
|
||||
*IRQ_ENABLE = IRQ_RASTER
|
||||
*KERNEL_IRQ = &irq
|
||||
@ -215,7 +215,7 @@ const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte* IRQ_STATUS = (byte*)$d019
|
||||
const nomodify void()** KERNEL_IRQ = (void()**)$314
|
||||
const nomodify byte* RASTER = (byte*)$d012
|
||||
const nomodify byte* VIC_CONTROL = (byte*)$d011
|
||||
const nomodify byte* VICII_CONTROL = (byte*)$d011
|
||||
void __start()
|
||||
__interrupt(rom_min_c64) void irq()
|
||||
byte~ irq::$2
|
||||
@ -320,7 +320,7 @@ byte sub_main::k#0
|
||||
byte sub_main::k#1
|
||||
byte sub_main::k#2
|
||||
|
||||
Adding number conversion cast (unumber) $7f in *VIC_CONTROL = *VIC_CONTROL & $7f
|
||||
Adding number conversion cast (unumber) $7f in *VICII_CONTROL = *VICII_CONTROL & $7f
|
||||
Adding number conversion cast (unumber) $fd in *RASTER = $fd
|
||||
Successful SSA optimization PassNAddNumberTypeConversions
|
||||
Inlining cast *RASTER = (unumber)$fd
|
||||
@ -588,7 +588,7 @@ void main()
|
||||
main: scope:[main] from
|
||||
asm { sei }
|
||||
[18] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
[19] *VIC_CONTROL = *VIC_CONTROL & $7f
|
||||
[19] *VICII_CONTROL = *VICII_CONTROL & $7f
|
||||
[20] *RASTER = $fd
|
||||
[21] *IRQ_ENABLE = IRQ_RASTER
|
||||
[22] *KERNEL_IRQ = &irq
|
||||
@ -804,7 +804,7 @@ Removing always clobbered register reg byte a as potential for zp[1]:4 [ irq::k#
|
||||
Statement [5] irq::$3 = irq::$2 + irq::k#2 [ irq::i#7 irq::j#4 irq::k#2 irq::$3 ] ( [ irq::i#7 irq::j#4 irq::k#2 irq::$3 ] { } ) always clobbers reg byte a
|
||||
Statement [14] *IRQ_STATUS = IRQ_RASTER [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [18] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [19] *VIC_CONTROL = *VIC_CONTROL & $7f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [19] *VICII_CONTROL = *VICII_CONTROL & $7f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [20] *RASTER = $fd [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [21] *IRQ_ENABLE = IRQ_RASTER [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [22] *KERNEL_IRQ = &irq [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
@ -827,7 +827,7 @@ Statement [4] irq::$2 = irq::i#7 + irq::j#4 [ irq::i#7 irq::j#4 irq::k#2 irq::$2
|
||||
Statement [5] irq::$3 = irq::$2 + irq::k#2 [ irq::i#7 irq::j#4 irq::k#2 irq::$3 ] ( [ irq::i#7 irq::j#4 irq::k#2 irq::$3 ] { } ) always clobbers reg byte a
|
||||
Statement [14] *IRQ_STATUS = IRQ_RASTER [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [18] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [19] *VIC_CONTROL = *VIC_CONTROL & $7f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [19] *VICII_CONTROL = *VICII_CONTROL & $7f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [20] *RASTER = $fd [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [21] *IRQ_ENABLE = IRQ_RASTER [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [22] *KERNEL_IRQ = &irq [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
@ -909,7 +909,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
.label KERNEL_IRQ = $314
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -1026,11 +1026,11 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// [19] *VIC_CONTROL = *VIC_CONTROL & $7f -- _deref_pbuc1=_deref_pbuc1_band_vbuc2
|
||||
// [19] *VICII_CONTROL = *VICII_CONTROL & $7f -- _deref_pbuc1=_deref_pbuc1_band_vbuc2
|
||||
// Set raster line to $0fd
|
||||
lda #$7f
|
||||
and VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
and VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// [20] *RASTER = $fd -- _deref_pbuc1=vbuc2
|
||||
lda #$fd
|
||||
sta RASTER
|
||||
@ -1402,7 +1402,7 @@ const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte* IRQ_STATUS = (byte*) 53273
|
||||
const nomodify void()** KERNEL_IRQ = (void()**) 788
|
||||
const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* VIC_CONTROL = (byte*) 53265
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
__interrupt(rom_min_c64) void irq()
|
||||
byte~ irq::$2 reg byte a 2002.0
|
||||
byte~ irq::$3 reg byte a 2002.0
|
||||
@ -1493,7 +1493,7 @@ Score: 314173671
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
.label KERNEL_IRQ = $314
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -1598,12 +1598,12 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// *VIC_CONTROL &=$7f
|
||||
// [19] *VIC_CONTROL = *VIC_CONTROL & $7f -- _deref_pbuc1=_deref_pbuc1_band_vbuc2
|
||||
// *VICII_CONTROL &=$7f
|
||||
// [19] *VICII_CONTROL = *VICII_CONTROL & $7f -- _deref_pbuc1=_deref_pbuc1_band_vbuc2
|
||||
// Set raster line to $0fd
|
||||
lda #$7f
|
||||
and VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
and VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// *RASTER = $fd
|
||||
// [20] *RASTER = $fd -- _deref_pbuc1=vbuc2
|
||||
lda #$fd
|
||||
|
@ -7,7 +7,7 @@ const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte* IRQ_STATUS = (byte*) 53273
|
||||
const nomodify void()** KERNEL_IRQ = (void()**) 788
|
||||
const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* VIC_CONTROL = (byte*) 53265
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
__interrupt(rom_min_c64) void irq()
|
||||
byte~ irq::$2 reg byte a 2002.0
|
||||
byte~ irq::$3 reg byte a 2002.0
|
||||
|
@ -13,7 +13,7 @@
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
.label KERNEL_IRQ = $314
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -41,11 +41,11 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// *VIC_CONTROL |=$80
|
||||
// *VICII_CONTROL |=$80
|
||||
// Set raster line to $100
|
||||
lda #$80
|
||||
ora VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
ora VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// *RASTER = $00
|
||||
lda #0
|
||||
sta RASTER
|
||||
|
@ -13,7 +13,7 @@ void main()
|
||||
main: scope:[main] from
|
||||
asm { sei }
|
||||
[5] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
[6] *VIC_CONTROL = *VIC_CONTROL | $80
|
||||
[6] *VICII_CONTROL = *VICII_CONTROL | $80
|
||||
[7] *RASTER = 0
|
||||
[8] *IRQ_ENABLE = IRQ_RASTER
|
||||
[9] *KERNEL_IRQ = &irq
|
||||
|
@ -6,7 +6,7 @@ void main()
|
||||
main: scope:[main] from __start
|
||||
asm { sei }
|
||||
*CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
*VIC_CONTROL = *VIC_CONTROL | $80
|
||||
*VICII_CONTROL = *VICII_CONTROL | $80
|
||||
*RASTER = 0
|
||||
*IRQ_ENABLE = IRQ_RASTER
|
||||
*KERNEL_IRQ = &irq
|
||||
@ -46,13 +46,13 @@ const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte* IRQ_STATUS = (byte*)$d019
|
||||
const nomodify void()** KERNEL_IRQ = (void()**)$314
|
||||
const nomodify byte* RASTER = (byte*)$d012
|
||||
const nomodify byte* VIC_CONTROL = (byte*)$d011
|
||||
const nomodify byte* VICII_CONTROL = (byte*)$d011
|
||||
const nomodify byte WHITE = 1
|
||||
void __start()
|
||||
__interrupt(rom_min_c64) void irq()
|
||||
void main()
|
||||
|
||||
Adding number conversion cast (unumber) $80 in *VIC_CONTROL = *VIC_CONTROL | $80
|
||||
Adding number conversion cast (unumber) $80 in *VICII_CONTROL = *VICII_CONTROL | $80
|
||||
Adding number conversion cast (unumber) 0 in *RASTER = 0
|
||||
Successful SSA optimization PassNAddNumberTypeConversions
|
||||
Inlining cast *RASTER = (unumber)0
|
||||
@ -96,7 +96,7 @@ void main()
|
||||
main: scope:[main] from
|
||||
asm { sei }
|
||||
[5] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
[6] *VIC_CONTROL = *VIC_CONTROL | $80
|
||||
[6] *VICII_CONTROL = *VICII_CONTROL | $80
|
||||
[7] *RASTER = 0
|
||||
[8] *IRQ_ENABLE = IRQ_RASTER
|
||||
[9] *KERNEL_IRQ = &irq
|
||||
@ -118,7 +118,7 @@ Statement [0] *BG_COLOR = WHITE [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [1] *BG_COLOR = BLACK [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [2] *IRQ_STATUS = IRQ_RASTER [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [5] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [6] *VIC_CONTROL = *VIC_CONTROL | $80 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [6] *VICII_CONTROL = *VICII_CONTROL | $80 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [7] *RASTER = 0 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [8] *IRQ_ENABLE = IRQ_RASTER [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [9] *KERNEL_IRQ = &irq [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
@ -151,7 +151,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
.label KERNEL_IRQ = $314
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -186,11 +186,11 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// [6] *VIC_CONTROL = *VIC_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// [6] *VICII_CONTROL = *VICII_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// Set raster line to $100
|
||||
lda #$80
|
||||
ora VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
ora VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// [7] *RASTER = 0 -- _deref_pbuc1=vbuc2
|
||||
lda #0
|
||||
sta RASTER
|
||||
@ -232,7 +232,7 @@ const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte* IRQ_STATUS = (byte*) 53273
|
||||
const nomodify void()** KERNEL_IRQ = (void()**) 788
|
||||
const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* VIC_CONTROL = (byte*) 53265
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
const nomodify byte WHITE = 1
|
||||
__interrupt(rom_min_c64) void irq()
|
||||
void main()
|
||||
@ -260,7 +260,7 @@ Score: 98
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
.label KERNEL_IRQ = $314
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -299,12 +299,12 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// *VIC_CONTROL |=$80
|
||||
// [6] *VIC_CONTROL = *VIC_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// *VICII_CONTROL |=$80
|
||||
// [6] *VICII_CONTROL = *VICII_CONTROL | $80 -- _deref_pbuc1=_deref_pbuc1_bor_vbuc2
|
||||
// Set raster line to $100
|
||||
lda #$80
|
||||
ora VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
ora VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// *RASTER = $00
|
||||
// [7] *RASTER = 0 -- _deref_pbuc1=vbuc2
|
||||
lda #0
|
||||
|
@ -7,7 +7,7 @@ const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte* IRQ_STATUS = (byte*) 53273
|
||||
const nomodify void()** KERNEL_IRQ = (void()**) 788
|
||||
const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* VIC_CONTROL = (byte*) 53265
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
const nomodify byte WHITE = 1
|
||||
__interrupt(rom_min_c64) void irq()
|
||||
void main()
|
||||
|
@ -12,7 +12,7 @@
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
.label KERNEL_IRQ = $314
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -39,11 +39,11 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// *VIC_CONTROL &=$7f
|
||||
// *VICII_CONTROL &=$7f
|
||||
// Set raster line to $0fd
|
||||
lda #$7f
|
||||
and VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
and VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// *RASTER = $fd
|
||||
lda #$fd
|
||||
sta RASTER
|
||||
|
@ -19,7 +19,7 @@ void main()
|
||||
main: scope:[main] from
|
||||
asm { sei }
|
||||
[7] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
[8] *VIC_CONTROL = *VIC_CONTROL & $7f
|
||||
[8] *VICII_CONTROL = *VICII_CONTROL & $7f
|
||||
[9] *RASTER = $fd
|
||||
[10] *IRQ_ENABLE = IRQ_RASTER
|
||||
[11] *KERNEL_IRQ = &irq
|
||||
|
@ -8,7 +8,7 @@ void main()
|
||||
main: scope:[main] from __start::@1
|
||||
asm { sei }
|
||||
*CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
*VIC_CONTROL = *VIC_CONTROL & $7f
|
||||
*VICII_CONTROL = *VICII_CONTROL & $7f
|
||||
*RASTER = $fd
|
||||
*IRQ_ENABLE = IRQ_RASTER
|
||||
*KERNEL_IRQ = &irq
|
||||
@ -68,7 +68,7 @@ const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte* IRQ_STATUS = (byte*)$d019
|
||||
const nomodify void()** KERNEL_IRQ = (void()**)$314
|
||||
const nomodify byte* RASTER = (byte*)$d012
|
||||
const nomodify byte* VIC_CONTROL = (byte*)$d011
|
||||
const nomodify byte* VICII_CONTROL = (byte*)$d011
|
||||
void __start()
|
||||
__interrupt(rom_min_c64) void irq()
|
||||
bool~ irq::$1
|
||||
@ -77,7 +77,7 @@ void main()
|
||||
bool~ main::$0
|
||||
bool~ main::$1
|
||||
|
||||
Adding number conversion cast (unumber) $7f in *VIC_CONTROL = *VIC_CONTROL & $7f
|
||||
Adding number conversion cast (unumber) $7f in *VICII_CONTROL = *VICII_CONTROL & $7f
|
||||
Adding number conversion cast (unumber) $fd in *RASTER = $fd
|
||||
Adding number conversion cast (unumber) $14 in main::$0 = *RASTER < $14
|
||||
Adding number conversion cast (unumber) $32 in irq::$1 = *RASTER > $32
|
||||
@ -162,7 +162,7 @@ void main()
|
||||
main: scope:[main] from
|
||||
asm { sei }
|
||||
[7] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR
|
||||
[8] *VIC_CONTROL = *VIC_CONTROL & $7f
|
||||
[8] *VICII_CONTROL = *VICII_CONTROL & $7f
|
||||
[9] *RASTER = $fd
|
||||
[10] *IRQ_ENABLE = IRQ_RASTER
|
||||
[11] *KERNEL_IRQ = &irq
|
||||
@ -186,7 +186,7 @@ REGISTER UPLIFT POTENTIAL REGISTERS
|
||||
Statement [1] *IRQ_STATUS = IRQ_RASTER [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [2] if(*RASTER<$32+1) goto irq::@1 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [7] *CIA1_INTERRUPT = CIA_INTERRUPT_CLEAR [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [8] *VIC_CONTROL = *VIC_CONTROL & $7f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [8] *VICII_CONTROL = *VICII_CONTROL & $7f [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [9] *RASTER = $fd [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [10] *IRQ_ENABLE = IRQ_RASTER [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [11] *KERNEL_IRQ = &irq [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
@ -219,7 +219,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
.label KERNEL_IRQ = $314
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -262,11 +262,11 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// [8] *VIC_CONTROL = *VIC_CONTROL & $7f -- _deref_pbuc1=_deref_pbuc1_band_vbuc2
|
||||
// [8] *VICII_CONTROL = *VICII_CONTROL & $7f -- _deref_pbuc1=_deref_pbuc1_band_vbuc2
|
||||
// Set raster line to $0fd
|
||||
lda #$7f
|
||||
and VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
and VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// [9] *RASTER = $fd -- _deref_pbuc1=vbuc2
|
||||
lda #$fd
|
||||
sta RASTER
|
||||
@ -326,7 +326,7 @@ const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte* IRQ_STATUS = (byte*) 53273
|
||||
const nomodify void()** KERNEL_IRQ = (void()**) 788
|
||||
const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* VIC_CONTROL = (byte*) 53265
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
__interrupt(rom_min_c64) void irq()
|
||||
void main()
|
||||
|
||||
@ -352,7 +352,7 @@ Score: 978
|
||||
.const CIA_INTERRUPT_CLEAR = $7f
|
||||
.label KERNEL_IRQ = $314
|
||||
.label RASTER = $d012
|
||||
.label VIC_CONTROL = $d011
|
||||
.label VICII_CONTROL = $d011
|
||||
.label IRQ_STATUS = $d019
|
||||
.label IRQ_ENABLE = $d01a
|
||||
.label BG_COLOR = $d020
|
||||
@ -394,12 +394,12 @@ main: {
|
||||
// Disable CIA 1 Timer IRQ
|
||||
lda #CIA_INTERRUPT_CLEAR
|
||||
sta CIA1_INTERRUPT
|
||||
// *VIC_CONTROL &=$7f
|
||||
// [8] *VIC_CONTROL = *VIC_CONTROL & $7f -- _deref_pbuc1=_deref_pbuc1_band_vbuc2
|
||||
// *VICII_CONTROL &=$7f
|
||||
// [8] *VICII_CONTROL = *VICII_CONTROL & $7f -- _deref_pbuc1=_deref_pbuc1_band_vbuc2
|
||||
// Set raster line to $0fd
|
||||
lda #$7f
|
||||
and VIC_CONTROL
|
||||
sta VIC_CONTROL
|
||||
and VICII_CONTROL
|
||||
sta VICII_CONTROL
|
||||
// *RASTER = $fd
|
||||
// [9] *RASTER = $fd -- _deref_pbuc1=vbuc2
|
||||
lda #$fd
|
||||
|
@ -6,7 +6,7 @@ const nomodify byte IRQ_RASTER = 1
|
||||
const nomodify byte* IRQ_STATUS = (byte*) 53273
|
||||
const nomodify void()** KERNEL_IRQ = (void()**) 788
|
||||
const nomodify byte* RASTER = (byte*) 53266
|
||||
const nomodify byte* VIC_CONTROL = (byte*) 53265
|
||||
const nomodify byte* VICII_CONTROL = (byte*) 53265
|
||||
__interrupt(rom_min_c64) void irq()
|
||||
void main()
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
.segmentdef Data [startAfter="Code"]
|
||||
.segment Basic
|
||||
:BasicUpstart(main)
|
||||
.label VIC_MEMORY = $d018
|
||||
.label VICII_MEMORY = $d018
|
||||
.label SCREEN = $400
|
||||
.label CHARSET = $3000
|
||||
.segment Code
|
||||
@ -25,9 +25,9 @@ main: {
|
||||
lda #4
|
||||
cmp.z c
|
||||
bne __b2
|
||||
// *VIC_MEMORY = (byte)(((word)SCREEN/$40)|((word)CHARSET/$400))
|
||||
// *VICII_MEMORY = (byte)(((word)SCREEN/$40)|((word)CHARSET/$400))
|
||||
lda #SCREEN/$40|CHARSET/$400
|
||||
sta VIC_MEMORY
|
||||
sta VICII_MEMORY
|
||||
// }
|
||||
rts
|
||||
__b2:
|
||||
|
@ -9,7 +9,7 @@ main::@1: scope:[main] from main main::@4
|
||||
[2] if(main::c#2!=4) goto main::@2
|
||||
to:main::@3
|
||||
main::@3: scope:[main] from main::@1
|
||||
[3] *VIC_MEMORY = (byte)(word)SCREEN/$40|(word)CHARSET/$400
|
||||
[3] *VICII_MEMORY = (byte)(word)SCREEN/$40|(word)CHARSET/$400
|
||||
to:main::@return
|
||||
main::@return: scope:[main] from main::@3
|
||||
[4] return
|
||||
|
@ -35,7 +35,7 @@ main::@3: scope:[main] from main::@1
|
||||
main::$9 = (word)CHARSET
|
||||
main::$2 = main::$9 / $400
|
||||
main::$3 = main::$1 | main::$2
|
||||
*VIC_MEMORY = (byte)main::$3
|
||||
*VICII_MEMORY = (byte)main::$3
|
||||
to:main::@return
|
||||
main::@return: scope:[main] from main::@3
|
||||
return
|
||||
@ -121,7 +121,7 @@ SYMBOL TABLE SSA
|
||||
const byte* CHARSET = (byte*)$3000
|
||||
const byte* SCREEN = (byte*)$400
|
||||
const byte SIZEOF_WORD = 2
|
||||
const byte* VIC_MEMORY = (byte*)$d018
|
||||
const byte* VICII_MEMORY = (byte*)$d018
|
||||
void __start()
|
||||
const word* charset_spec_row[] = { $f7da, $f7de, $f24e, $d6de }
|
||||
void gen_char3(byte* gen_char3::dst , word gen_char3::spec)
|
||||
@ -322,7 +322,7 @@ Constant right-side identified [8] main::$3 = main::$1 | main::$2
|
||||
Successful SSA optimization Pass2ConstantRValueConsolidation
|
||||
Constant main::$3 = main::$1|main::$2
|
||||
Successful SSA optimization Pass2ConstantIdentification
|
||||
Constant value identified (byte)main::$3 in [9] *VIC_MEMORY = (byte)main::$3
|
||||
Constant value identified (byte)main::$3 in [9] *VICII_MEMORY = (byte)main::$3
|
||||
Successful SSA optimization Pass2ConstantValues
|
||||
Rewriting multiplication to use shift [2] main::$7 = main::c#2 * SIZEOF_WORD
|
||||
Rewriting multiplication to use shift [16] gen_char3::b#1 = gen_char3::b#3 * 2
|
||||
@ -384,7 +384,7 @@ main::@1: scope:[main] from main main::@4
|
||||
[2] if(main::c#2!=4) goto main::@2
|
||||
to:main::@3
|
||||
main::@3: scope:[main] from main::@1
|
||||
[3] *VIC_MEMORY = (byte)(word)SCREEN/$40|(word)CHARSET/$400
|
||||
[3] *VICII_MEMORY = (byte)(word)SCREEN/$40|(word)CHARSET/$400
|
||||
to:main::@return
|
||||
main::@return: scope:[main] from main::@3
|
||||
[4] return
|
||||
@ -500,7 +500,7 @@ Allocated zp[2]:11 [ gen_char3::dst#0 ]
|
||||
Allocated zp[1]:13 [ gen_char3::$0 ]
|
||||
Allocated zp[1]:14 [ gen_char3::$1 ]
|
||||
REGISTER UPLIFT POTENTIAL REGISTERS
|
||||
Statement [3] *VIC_MEMORY = (byte)(word)SCREEN/$40|(word)CHARSET/$400 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [3] *VICII_MEMORY = (byte)(word)SCREEN/$40|(word)CHARSET/$400 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [5] main::$7 = main::c#2 << 1 [ main::c#2 main::charset#2 main::$7 ] ( [ main::c#2 main::charset#2 main::$7 ] { { gen_char3::dst#0 = main::charset#2 } } ) always clobbers reg byte a
|
||||
Removing always clobbered register reg byte a as potential for zp[1]:2 [ main::c#2 main::c#1 ]
|
||||
Statement [6] gen_char3::dst#0 = main::charset#2 [ main::c#2 main::charset#2 main::$7 gen_char3::dst#0 ] ( [ main::c#2 main::charset#2 main::$7 gen_char3::dst#0 ] { { gen_char3::dst#0 = main::charset#2 } } ) always clobbers reg byte a
|
||||
@ -510,7 +510,7 @@ Statement [9] main::charset#1 = main::charset#2 + 8 [ main::c#2 main::charset#1
|
||||
Statement [17] gen_char3::b#2 = gen_char3::b#4 | 1 [ gen_char3::dst#0 gen_char3::r#6 gen_char3::spec#2 gen_char3::c#2 gen_char3::b#2 ] ( gen_char3:8 [ main::c#2 main::charset#2 gen_char3::dst#0 gen_char3::r#6 gen_char3::spec#2 gen_char3::c#2 gen_char3::b#2 ] { { gen_char3::dst#0 = main::charset#2 } } ) always clobbers reg byte a
|
||||
Removing always clobbered register reg byte a as potential for zp[1]:5 [ gen_char3::r#6 gen_char3::r#1 ]
|
||||
Removing always clobbered register reg byte a as potential for zp[1]:8 [ gen_char3::c#2 gen_char3::c#1 ]
|
||||
Statement [3] *VIC_MEMORY = (byte)(word)SCREEN/$40|(word)CHARSET/$400 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [3] *VICII_MEMORY = (byte)(word)SCREEN/$40|(word)CHARSET/$400 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [5] main::$7 = main::c#2 << 1 [ main::c#2 main::charset#2 main::$7 ] ( [ main::c#2 main::charset#2 main::$7 ] { { gen_char3::dst#0 = main::charset#2 } } ) always clobbers reg byte a
|
||||
Statement [6] gen_char3::dst#0 = main::charset#2 [ main::c#2 main::charset#2 main::$7 gen_char3::dst#0 ] ( [ main::c#2 main::charset#2 main::$7 gen_char3::dst#0 ] { { gen_char3::dst#0 = main::charset#2 } } ) always clobbers reg byte a
|
||||
Statement [7] gen_char3::spec#0 = charset_spec_row[main::$7] [ main::c#2 main::charset#2 gen_char3::dst#0 gen_char3::spec#0 ] ( [ main::c#2 main::charset#2 gen_char3::dst#0 gen_char3::spec#0 ] { { gen_char3::dst#0 = main::charset#2 } } ) always clobbers reg byte a
|
||||
@ -555,7 +555,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
.segment Basic
|
||||
:BasicUpstart(main)
|
||||
// Global Constants & labels
|
||||
.label VIC_MEMORY = $d018
|
||||
.label VICII_MEMORY = $d018
|
||||
.label SCREEN = $400
|
||||
.label CHARSET = $3000
|
||||
.segment Code
|
||||
@ -583,9 +583,9 @@ main: {
|
||||
jmp __b3
|
||||
// main::@3
|
||||
__b3:
|
||||
// [3] *VIC_MEMORY = (byte)(word)SCREEN/$40|(word)CHARSET/$400 -- _deref_pbuc1=vbuc2
|
||||
// [3] *VICII_MEMORY = (byte)(word)SCREEN/$40|(word)CHARSET/$400 -- _deref_pbuc1=vbuc2
|
||||
lda #SCREEN/$40|CHARSET/$400
|
||||
sta VIC_MEMORY
|
||||
sta VICII_MEMORY
|
||||
jmp __breturn
|
||||
// main::@return
|
||||
__breturn:
|
||||
@ -761,7 +761,7 @@ Succesful ASM optimization Pass5NextJumpElimination
|
||||
FINAL SYMBOL TABLE
|
||||
const byte* CHARSET = (byte*) 12288
|
||||
const byte* SCREEN = (byte*) 1024
|
||||
const byte* VIC_MEMORY = (byte*) 53272
|
||||
const byte* VICII_MEMORY = (byte*) 53272
|
||||
const word* charset_spec_row[] = { $f7da, $f7de, $f24e, $d6de }
|
||||
void gen_char3(byte* gen_char3::dst , word gen_char3::spec)
|
||||
byte~ gen_char3::$0 reg byte a 200002.0
|
||||
@ -819,7 +819,7 @@ Score: 45574
|
||||
.segment Basic
|
||||
:BasicUpstart(main)
|
||||
// Global Constants & labels
|
||||
.label VIC_MEMORY = $d018
|
||||
.label VICII_MEMORY = $d018
|
||||
.label SCREEN = $400
|
||||
.label CHARSET = $3000
|
||||
.segment Code
|
||||
@ -844,10 +844,10 @@ main: {
|
||||
cmp.z c
|
||||
bne __b2
|
||||
// main::@3
|
||||
// *VIC_MEMORY = (byte)(((word)SCREEN/$40)|((word)CHARSET/$400))
|
||||
// [3] *VIC_MEMORY = (byte)(word)SCREEN/$40|(word)CHARSET/$400 -- _deref_pbuc1=vbuc2
|
||||
// *VICII_MEMORY = (byte)(((word)SCREEN/$40)|((word)CHARSET/$400))
|
||||
// [3] *VICII_MEMORY = (byte)(word)SCREEN/$40|(word)CHARSET/$400 -- _deref_pbuc1=vbuc2
|
||||
lda #SCREEN/$40|CHARSET/$400
|
||||
sta VIC_MEMORY
|
||||
sta VICII_MEMORY
|
||||
// main::@return
|
||||
// }
|
||||
// [4] return
|
||||
|
@ -1,6 +1,6 @@
|
||||
const byte* CHARSET = (byte*) 12288
|
||||
const byte* SCREEN = (byte*) 1024
|
||||
const byte* VIC_MEMORY = (byte*) 53272
|
||||
const byte* VICII_MEMORY = (byte*) 53272
|
||||
const word* charset_spec_row[] = { $f7da, $f7de, $f24e, $d6de }
|
||||
void gen_char3(byte* gen_char3::dst , word gen_char3::spec)
|
||||
byte~ gen_char3::$0 reg byte a 200002.0
|
||||
|
@ -9,7 +9,7 @@
|
||||
.segment Basic
|
||||
:BasicUpstart(main)
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
.label SPRITES_XPOS = $d000
|
||||
.label SPRITES_YPOS = $d001
|
||||
.label SPRITES_ENABLE = $d015
|
||||
@ -28,9 +28,9 @@ main: {
|
||||
sta SPRITES_YPOS
|
||||
// SPRITES_XPOS[0] = 100
|
||||
sta SPRITES_XPOS
|
||||
// *(SCREEN+SPRITE_PTRS) = (byte)(SPRITE/0x40)
|
||||
// *(SCREEN+OFFSET_SPRITE_PTRS) = (byte)(SPRITE/0x40)
|
||||
lda #$ff&SPRITE/$40
|
||||
sta SCREEN+SPRITE_PTRS
|
||||
sta SCREEN+OFFSET_SPRITE_PTRS
|
||||
// saveZeropage()
|
||||
jsr saveZeropage
|
||||
// sinZeropage()
|
||||
|
@ -5,7 +5,7 @@ main: scope:[main] from
|
||||
[1] *SPRITES_ENABLE = 1
|
||||
[2] *SPRITES_YPOS = $64
|
||||
[3] *SPRITES_XPOS = $64
|
||||
[4] *(SCREEN+SPRITE_PTRS) = (byte)SPRITE/$40
|
||||
[4] *(SCREEN+OFFSET_SPRITE_PTRS) = (byte)SPRITE/$40
|
||||
[5] call saveZeropage
|
||||
to:main::@1
|
||||
main::@1: scope:[main] from main
|
||||
|
@ -8,7 +8,7 @@ main: scope:[main] from __start
|
||||
*SPRITES_ENABLE = 1
|
||||
SPRITES_YPOS[0] = $64
|
||||
SPRITES_XPOS[0] = $64
|
||||
*(SCREEN+SPRITE_PTRS) = (byte)SPRITE/$40
|
||||
*(SCREEN+OFFSET_SPRITE_PTRS) = (byte)SPRITE/$40
|
||||
call saveZeropage
|
||||
to:main::@1
|
||||
main::@1: scope:[main] from main
|
||||
@ -89,6 +89,7 @@ __start::@return: scope:[__start] from __start::@1
|
||||
to:@return
|
||||
|
||||
SYMBOL TABLE SSA
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const nomodify byte* SCREEN = (byte*)$400
|
||||
const to_nomodify byte* SINTABLE[$100] = kickasm {{ .for(var i=0;i<$100;i++)
|
||||
.byte round(127.5+127.5*cos(toRadians(360*i/256)))
|
||||
@ -97,7 +98,6 @@ const to_nomodify byte* SPRITE[$40] = kickasm {{ .fill $40,$ff }}
|
||||
const nomodify byte* SPRITES_ENABLE = (byte*)$d015
|
||||
const nomodify byte* SPRITES_XPOS = (byte*)$d000
|
||||
const nomodify byte* SPRITES_YPOS = (byte*)$d001
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const to_nomodify byte* ZP_STORAGE[$100] = { fill( $100, 0) }
|
||||
void __start()
|
||||
void animSprite()
|
||||
@ -111,7 +111,7 @@ Adding number conversion cast (unumber) $64 in SPRITES_YPOS[0] = $64
|
||||
Adding number conversion cast (unumber) 0 in SPRITES_YPOS[0] = ((unumber)) $64
|
||||
Adding number conversion cast (unumber) $64 in SPRITES_XPOS[0] = $64
|
||||
Adding number conversion cast (unumber) 0 in SPRITES_XPOS[0] = ((unumber)) $64
|
||||
Adding number conversion cast (unumber) $40 in *(SCREEN+SPRITE_PTRS) = (byte)SPRITE/$40
|
||||
Adding number conversion cast (unumber) $40 in *(SCREEN+OFFSET_SPRITE_PTRS) = (byte)SPRITE/$40
|
||||
Successful SSA optimization PassNAddNumberTypeConversions
|
||||
Inlining cast *SPRITES_ENABLE = (unumber)1
|
||||
Inlining cast SPRITES_YPOS[(unumber)0] = (unumber)$64
|
||||
@ -170,7 +170,7 @@ main: scope:[main] from
|
||||
[1] *SPRITES_ENABLE = 1
|
||||
[2] *SPRITES_YPOS = $64
|
||||
[3] *SPRITES_XPOS = $64
|
||||
[4] *(SCREEN+SPRITE_PTRS) = (byte)SPRITE/$40
|
||||
[4] *(SCREEN+OFFSET_SPRITE_PTRS) = (byte)SPRITE/$40
|
||||
[5] call saveZeropage
|
||||
to:main::@1
|
||||
main::@1: scope:[main] from main
|
||||
@ -255,7 +255,7 @@ REGISTER UPLIFT POTENTIAL REGISTERS
|
||||
Statement [1] *SPRITES_ENABLE = 1 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [2] *SPRITES_YPOS = $64 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [3] *SPRITES_XPOS = $64 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [4] *(SCREEN+SPRITE_PTRS) = (byte)SPRITE/$40 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement [4] *(SCREEN+OFFSET_SPRITE_PTRS) = (byte)SPRITE/$40 [ ] ( [ ] { } ) always clobbers reg byte a
|
||||
Statement asm { ldx#0 !: lda$00,x staZP_STORAGE,x inx bne!- } always clobbers reg byte a reg byte x
|
||||
Statement asm { ldx#0 !: ldaSINTABLE,x sta$00,x inx bne!- } always clobbers reg byte a reg byte x
|
||||
Statement asm { ldx#0 !: ldaZP_STORAGE,x sta$00,x inx bne!- } always clobbers reg byte a reg byte x
|
||||
@ -296,7 +296,7 @@ ASSEMBLER BEFORE OPTIMIZATION
|
||||
:BasicUpstart(main)
|
||||
// Global Constants & labels
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
.label SPRITES_XPOS = $d000
|
||||
.label SPRITES_YPOS = $d001
|
||||
.label SPRITES_ENABLE = $d015
|
||||
@ -317,9 +317,9 @@ main: {
|
||||
// [3] *SPRITES_XPOS = $64 -- _deref_pbuc1=vbuc2
|
||||
lda #$64
|
||||
sta SPRITES_XPOS
|
||||
// [4] *(SCREEN+SPRITE_PTRS) = (byte)SPRITE/$40 -- _deref_pbuc1=vbuc2
|
||||
// [4] *(SCREEN+OFFSET_SPRITE_PTRS) = (byte)SPRITE/$40 -- _deref_pbuc1=vbuc2
|
||||
lda #$ff&SPRITE/$40
|
||||
sta SCREEN+SPRITE_PTRS
|
||||
sta SCREEN+OFFSET_SPRITE_PTRS
|
||||
// [5] call saveZeropage
|
||||
jsr saveZeropage
|
||||
// [6] phi from main to main::@1 [phi:main->main::@1]
|
||||
@ -471,6 +471,7 @@ Removing instruction __breturn:
|
||||
Succesful ASM optimization Pass5UnusedLabelElimination
|
||||
|
||||
FINAL SYMBOL TABLE
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const nomodify byte* SCREEN = (byte*) 1024
|
||||
const to_nomodify byte* SINTABLE[$100] = kickasm {{ .for(var i=0;i<$100;i++)
|
||||
.byte round(127.5+127.5*cos(toRadians(360*i/256)))
|
||||
@ -479,7 +480,6 @@ const to_nomodify byte* SPRITE[$40] = kickasm {{ .fill $40,$ff }}
|
||||
const nomodify byte* SPRITES_ENABLE = (byte*) 53269
|
||||
const nomodify byte* SPRITES_XPOS = (byte*) 53248
|
||||
const nomodify byte* SPRITES_YPOS = (byte*) 53249
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const to_nomodify byte* ZP_STORAGE[$100] = { fill( $100, 0) }
|
||||
void animSprite()
|
||||
void main()
|
||||
@ -506,7 +506,7 @@ Score: 379
|
||||
:BasicUpstart(main)
|
||||
// Global Constants & labels
|
||||
// The offset of the sprite pointers from the screen start address
|
||||
.const SPRITE_PTRS = $3f8
|
||||
.const OFFSET_SPRITE_PTRS = $3f8
|
||||
.label SPRITES_XPOS = $d000
|
||||
.label SPRITES_YPOS = $d001
|
||||
.label SPRITES_ENABLE = $d015
|
||||
@ -530,10 +530,10 @@ main: {
|
||||
// SPRITES_XPOS[0] = 100
|
||||
// [3] *SPRITES_XPOS = $64 -- _deref_pbuc1=vbuc2
|
||||
sta SPRITES_XPOS
|
||||
// *(SCREEN+SPRITE_PTRS) = (byte)(SPRITE/0x40)
|
||||
// [4] *(SCREEN+SPRITE_PTRS) = (byte)SPRITE/$40 -- _deref_pbuc1=vbuc2
|
||||
// *(SCREEN+OFFSET_SPRITE_PTRS) = (byte)(SPRITE/0x40)
|
||||
// [4] *(SCREEN+OFFSET_SPRITE_PTRS) = (byte)SPRITE/$40 -- _deref_pbuc1=vbuc2
|
||||
lda #$ff&SPRITE/$40
|
||||
sta SCREEN+SPRITE_PTRS
|
||||
sta SCREEN+OFFSET_SPRITE_PTRS
|
||||
// saveZeropage()
|
||||
// [5] call saveZeropage
|
||||
jsr saveZeropage
|
||||
|
@ -1,3 +1,4 @@
|
||||
const nomodify word OFFSET_SPRITE_PTRS = $3f8
|
||||
const nomodify byte* SCREEN = (byte*) 1024
|
||||
const to_nomodify byte* SINTABLE[$100] = kickasm {{ .for(var i=0;i<$100;i++)
|
||||
.byte round(127.5+127.5*cos(toRadians(360*i/256)))
|
||||
@ -6,7 +7,6 @@ const to_nomodify byte* SPRITE[$40] = kickasm {{ .fill $40,$ff }}
|
||||
const nomodify byte* SPRITES_ENABLE = (byte*) 53269
|
||||
const nomodify byte* SPRITES_XPOS = (byte*) 53248
|
||||
const nomodify byte* SPRITES_YPOS = (byte*) 53249
|
||||
const nomodify word SPRITE_PTRS = $3f8
|
||||
const to_nomodify byte* ZP_STORAGE[$100] = { fill( $100, 0) }
|
||||
void animSprite()
|
||||
void main()
|
||||
|
Loading…
x
Reference in New Issue
Block a user