mirror of
https://gitlab.com/camelot/kickc.git
synced 2024-12-01 00:51:12 +00:00
Renamed to clearscreen. Added DEBUG.
This commit is contained in:
parent
bbbb25d9b1
commit
ef38dca7af
@ -46,8 +46,8 @@ public class TestPrograms {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testBlackhole() throws IOException, URISyntaxException {
|
public void testClearscreen() throws IOException, URISyntaxException {
|
||||||
compileAndCompare("complex/blackhole/blackhole", log());
|
compileAndCompare("complex/clearscreen/clearscreen");
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: Optimize unused IRQ's away (and other unused funtions that reference each other circularly)
|
// TODO: Optimize unused IRQ's away (and other unused funtions that reference each other circularly)
|
||||||
|
@ -2,6 +2,9 @@
|
|||||||
import "c64"
|
import "c64"
|
||||||
import "multiply"
|
import "multiply"
|
||||||
|
|
||||||
|
// Generate debug code (raster time usage etc.)
|
||||||
|
const bool DEBUG = false;
|
||||||
|
|
||||||
// Address of the screen
|
// Address of the screen
|
||||||
const byte* SCREEN = 0x0400;
|
const byte* SCREEN = 0x0400;
|
||||||
// Sprite data for the animating sprites
|
// Sprite data for the animating sprites
|
||||||
@ -197,13 +200,15 @@ void processChars() {
|
|||||||
processing->vx += VXSIN[xchar];
|
processing->vx += VXSIN[xchar];
|
||||||
processing->x += processing->vx;
|
processing->x += processing->vx;
|
||||||
byte ychar = (byte)(ypos/8) - BORDER_YPOS_TOP/8;
|
byte ychar = (byte)(ypos/8) - BORDER_YPOS_TOP/8;
|
||||||
processing->vy += VYSIN[ychar];
|
processing->vy += VYSIN[ychar];
|
||||||
processing->y += processing->vy;
|
processing->y += processing->vy;
|
||||||
}
|
}
|
||||||
numActive++;
|
numActive++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
*(SCREEN+999) = '0'+numActive;
|
if(DEBUG) {
|
||||||
|
*(SCREEN+999) = '0'+numActive;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// SQUARES_X[i] = (i-20)*(i-20)
|
// SQUARES_X[i] = (i-20)*(i-20)
|
||||||
@ -261,12 +266,14 @@ const byte RASTER_IRQ_TOP = 0x30;
|
|||||||
|
|
||||||
// Raster Interrupt at the top of the screen
|
// Raster Interrupt at the top of the screen
|
||||||
interrupt(hardware_all) void irqTop() {
|
interrupt(hardware_all) void irqTop() {
|
||||||
for( byte i: 0..4) {}
|
if(DEBUG) {
|
||||||
//*BORDERCOL = WHITE;
|
for( byte i: 0..4) {}
|
||||||
//*BGCOL = WHITE;
|
*BORDERCOL = WHITE;
|
||||||
for( byte i: 0..7) {}
|
*BGCOL = WHITE;
|
||||||
//*BORDERCOL = LIGHT_BLUE;
|
for( byte i: 0..7) {}
|
||||||
//*BGCOL = BLUE;
|
*BORDERCOL = LIGHT_BLUE;
|
||||||
|
*BGCOL = BLUE;
|
||||||
|
}
|
||||||
|
|
||||||
// Trigger IRQ at the middle of the screen
|
// Trigger IRQ at the middle of the screen
|
||||||
*RASTER = RASTER_IRQ_MIDDLE;
|
*RASTER = RASTER_IRQ_MIDDLE;
|
||||||
@ -277,14 +284,18 @@ interrupt(hardware_all) void irqTop() {
|
|||||||
|
|
||||||
const byte RASTER_IRQ_MIDDLE = 0xff;
|
const byte RASTER_IRQ_MIDDLE = 0xff;
|
||||||
|
|
||||||
// Raster Interrupt at the middle of the screen
|
// Raster Interrupt at the bottom of the screen
|
||||||
interrupt(hardware_all) void irqBottom() {
|
interrupt(hardware_all) void irqBottom() {
|
||||||
for( byte i: 0..4) {}
|
if(DEBUG) {
|
||||||
//*BORDERCOL = WHITE;
|
for( byte i: 0..4) {}
|
||||||
//*BGCOL = WHITE;
|
*BORDERCOL = WHITE;
|
||||||
|
*BGCOL = WHITE;
|
||||||
|
}
|
||||||
processChars();
|
processChars();
|
||||||
//*BORDERCOL = LIGHT_BLUE;
|
if(DEBUG) {
|
||||||
//*BGCOL = BLUE;
|
*BORDERCOL = LIGHT_BLUE;
|
||||||
|
*BGCOL = BLUE;
|
||||||
|
}
|
||||||
|
|
||||||
// Trigger IRQ at the top of the screen
|
// Trigger IRQ at the top of the screen
|
||||||
*RASTER = RASTER_IRQ_TOP;
|
*RASTER = RASTER_IRQ_TOP;
|
@ -755,16 +755,11 @@ mul8u: {
|
|||||||
rol mb+1
|
rol mb+1
|
||||||
jmp b1
|
jmp b1
|
||||||
}
|
}
|
||||||
// Raster Interrupt at the middle of the screen
|
// Raster Interrupt at the bottom of the screen
|
||||||
irqBottom: {
|
irqBottom: {
|
||||||
sta rega+1
|
sta rega+1
|
||||||
stx regx+1
|
stx regx+1
|
||||||
sty regy+1
|
sty regy+1
|
||||||
ldx #0
|
|
||||||
b1:
|
|
||||||
inx
|
|
||||||
cpx #5
|
|
||||||
bne b1
|
|
||||||
jsr processChars
|
jsr processChars
|
||||||
// Trigger IRQ at the top of the screen
|
// Trigger IRQ at the top of the screen
|
||||||
lda #RASTER_IRQ_TOP
|
lda #RASTER_IRQ_TOP
|
||||||
@ -786,8 +781,8 @@ irqBottom: {
|
|||||||
}
|
}
|
||||||
// Process any chars in the PROCESSING array
|
// Process any chars in the PROCESSING array
|
||||||
processChars: {
|
processChars: {
|
||||||
.label _16 = $38
|
.label _15 = $38
|
||||||
.label _26 = $36
|
.label _25 = $36
|
||||||
.label processing = $33
|
.label processing = $33
|
||||||
.label bitmask = $35
|
.label bitmask = $35
|
||||||
.label i = $1e
|
.label i = $1e
|
||||||
@ -894,19 +889,19 @@ processChars: {
|
|||||||
sta SPRITES_XPOS,x
|
sta SPRITES_XPOS,x
|
||||||
ldy #OFFSET_STRUCT_PROCESSINGSPRITE_Y
|
ldy #OFFSET_STRUCT_PROCESSINGSPRITE_Y
|
||||||
lda (processing),y
|
lda (processing),y
|
||||||
sta _16
|
sta _15
|
||||||
iny
|
iny
|
||||||
lda (processing),y
|
lda (processing),y
|
||||||
sta _16+1
|
sta _15+1
|
||||||
lsr _16+1
|
lsr _15+1
|
||||||
ror _16
|
ror _15
|
||||||
lsr _16+1
|
lsr _15+1
|
||||||
ror _16
|
ror _15
|
||||||
lsr _16+1
|
lsr _15+1
|
||||||
ror _16
|
ror _15
|
||||||
lsr _16+1
|
lsr _15+1
|
||||||
ror _16
|
ror _15
|
||||||
lda _16
|
lda _15
|
||||||
sta ypos
|
sta ypos
|
||||||
sta SPRITES_YPOS,x
|
sta SPRITES_YPOS,x
|
||||||
// Move sprite
|
// Move sprite
|
||||||
@ -964,17 +959,15 @@ processChars: {
|
|||||||
dey
|
dey
|
||||||
lda #<YPOS_BOTTOMMOST
|
lda #<YPOS_BOTTOMMOST
|
||||||
cmp (processing),y
|
cmp (processing),y
|
||||||
bcs !b6+
|
bcc b6
|
||||||
jmp b6
|
|
||||||
!b6:
|
|
||||||
!:
|
!:
|
||||||
lsr _26+1
|
lsr _25+1
|
||||||
ror _26
|
ror _25
|
||||||
lsr _26+1
|
lsr _25+1
|
||||||
ror _26
|
ror _25
|
||||||
lsr _26+1
|
lsr _25+1
|
||||||
ror _26
|
ror _25
|
||||||
lda _26
|
lda _25
|
||||||
sec
|
sec
|
||||||
sbc #BORDER_XPOS_LEFT/8
|
sbc #BORDER_XPOS_LEFT/8
|
||||||
asl
|
asl
|
||||||
@ -1038,9 +1031,6 @@ processChars: {
|
|||||||
beq !b1+
|
beq !b1+
|
||||||
jmp b1
|
jmp b1
|
||||||
!b1:
|
!b1:
|
||||||
lax numActive
|
|
||||||
axs #-['0']
|
|
||||||
stx SCREEN+$3e7
|
|
||||||
rts
|
rts
|
||||||
b6:
|
b6:
|
||||||
// Set status to FREE
|
// Set status to FREE
|
||||||
@ -1064,18 +1054,6 @@ irqTop: {
|
|||||||
sta rega+1
|
sta rega+1
|
||||||
stx regx+1
|
stx regx+1
|
||||||
sty regy+1
|
sty regy+1
|
||||||
ldx #0
|
|
||||||
b1:
|
|
||||||
inx
|
|
||||||
cpx #5
|
|
||||||
bne b1
|
|
||||||
ldx #0
|
|
||||||
//*BORDERCOL = WHITE;
|
|
||||||
//*BGCOL = WHITE;
|
|
||||||
b2:
|
|
||||||
inx
|
|
||||||
cpx #8
|
|
||||||
bne b2
|
|
||||||
// Trigger IRQ at the middle of the screen
|
// Trigger IRQ at the middle of the screen
|
||||||
lda #RASTER_IRQ_MIDDLE
|
lda #RASTER_IRQ_MIDDLE
|
||||||
sta RASTER
|
sta RASTER
|
@ -351,127 +351,108 @@ mul8u::@3: scope:[mul8u] from mul8u::@2 mul8u::@4
|
|||||||
irqBottom: scope:[irqBottom] from
|
irqBottom: scope:[irqBottom] from
|
||||||
[198] phi()
|
[198] phi()
|
||||||
to:irqBottom::@1
|
to:irqBottom::@1
|
||||||
irqBottom::@1: scope:[irqBottom] from irqBottom irqBottom::@1
|
irqBottom::@1: scope:[irqBottom] from irqBottom
|
||||||
[199] (byte) irqBottom::i#2 ← phi( irqBottom/(byte) 0 irqBottom::@1/(byte) irqBottom::i#1 )
|
[199] phi()
|
||||||
[200] (byte) irqBottom::i#1 ← ++ (byte) irqBottom::i#2
|
[200] call processChars
|
||||||
[201] if((byte) irqBottom::i#1!=(byte) 5) goto irqBottom::@1
|
|
||||||
to:irqBottom::@2
|
to:irqBottom::@2
|
||||||
irqBottom::@2: scope:[irqBottom] from irqBottom::@1
|
irqBottom::@2: scope:[irqBottom] from irqBottom::@1
|
||||||
[202] phi()
|
[201] *((const byte*) RASTER#0) ← (const byte) RASTER_IRQ_TOP#0
|
||||||
[203] call processChars
|
[202] *((const void()**) HARDWARE_IRQ#0) ← &interrupt(HARDWARE_ALL)(void()) irqTop()
|
||||||
to:irqBottom::@3
|
[203] *((const byte*) IRQ_STATUS#0) ← (const byte) IRQ_RASTER#0
|
||||||
irqBottom::@3: scope:[irqBottom] from irqBottom::@2
|
|
||||||
[204] *((const byte*) RASTER#0) ← (const byte) RASTER_IRQ_TOP#0
|
|
||||||
[205] *((const void()**) HARDWARE_IRQ#0) ← &interrupt(HARDWARE_ALL)(void()) irqTop()
|
|
||||||
[206] *((const byte*) IRQ_STATUS#0) ← (const byte) IRQ_RASTER#0
|
|
||||||
to:irqBottom::@return
|
to:irqBottom::@return
|
||||||
irqBottom::@return: scope:[irqBottom] from irqBottom::@3
|
irqBottom::@return: scope:[irqBottom] from irqBottom::@2
|
||||||
[207] return
|
[204] return
|
||||||
to:@return
|
to:@return
|
||||||
processChars: scope:[processChars] from irqBottom::@2
|
processChars: scope:[processChars] from irqBottom::@1
|
||||||
[208] phi()
|
[205] phi()
|
||||||
to:processChars::@1
|
to:processChars::@1
|
||||||
processChars::@1: scope:[processChars] from processChars processChars::@2
|
processChars::@1: scope:[processChars] from processChars processChars::@2
|
||||||
[209] (byte) processChars::numActive#10 ← phi( processChars/(byte) 0 processChars::@2/(byte) processChars::numActive#3 )
|
[206] (byte) processChars::numActive#10 ← phi( processChars/(byte) 0 processChars::@2/(byte) processChars::numActive#3 )
|
||||||
[209] (byte) processChars::i#10 ← phi( processChars/(byte) 0 processChars::@2/(byte) processChars::i#1 )
|
[206] (byte) processChars::i#10 ← phi( processChars/(byte) 0 processChars::@2/(byte) processChars::i#1 )
|
||||||
[210] (byte) processChars::$64 ← (byte) processChars::i#10 << (byte) 1
|
[207] (byte) processChars::$65 ← (byte) processChars::i#10 << (byte) 1
|
||||||
[211] (byte) processChars::$65 ← (byte) processChars::$64 + (byte) processChars::i#10
|
[208] (byte) processChars::$66 ← (byte) processChars::$65 + (byte) processChars::i#10
|
||||||
[212] (byte) processChars::$66 ← (byte) processChars::$65 << (byte) 2
|
[209] (byte) processChars::$67 ← (byte) processChars::$66 << (byte) 2
|
||||||
[213] (byte~) processChars::$36 ← (byte) processChars::$66 + (byte) processChars::i#10
|
[210] (byte~) processChars::$37 ← (byte) processChars::$67 + (byte) processChars::i#10
|
||||||
[214] (struct ProcessingSprite*) processChars::processing#0 ← (const struct ProcessingSprite[NUM_PROCESSING#0]) PROCESSING#0 + (byte~) processChars::$36
|
[211] (struct ProcessingSprite*) processChars::processing#0 ← (const struct ProcessingSprite[NUM_PROCESSING#0]) PROCESSING#0 + (byte~) processChars::$37
|
||||||
[215] (byte) processChars::bitmask#0 ← (byte) 1 << *((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_ID)
|
[212] (byte) processChars::bitmask#0 ← (byte) 1 << *((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_ID)
|
||||||
[216] if(*((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_STATUS)==(const byte) STATUS_FREE#0) goto processChars::@2
|
[213] if(*((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_STATUS)==(const byte) STATUS_FREE#0) goto processChars::@2
|
||||||
to:processChars::@10
|
to:processChars::@10
|
||||||
processChars::@10: scope:[processChars] from processChars::@1
|
processChars::@10: scope:[processChars] from processChars::@1
|
||||||
[217] if(*((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_STATUS)!=(const byte) STATUS_NEW#0) goto processChars::@3
|
[214] if(*((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_STATUS)!=(const byte) STATUS_NEW#0) goto processChars::@3
|
||||||
to:processChars::@11
|
to:processChars::@11
|
||||||
processChars::@11: scope:[processChars] from processChars::@10
|
processChars::@11: scope:[processChars] from processChars::@10
|
||||||
[218] *(*((byte**)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_SCREENPTR)) ← (byte) ' '
|
[215] *(*((byte**)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_SCREENPTR)) ← (byte) ' '
|
||||||
[219] *((const byte*) SPRITES_ENABLE#0) ← *((const byte*) SPRITES_ENABLE#0) | (byte) processChars::bitmask#0
|
[216] *((const byte*) SPRITES_ENABLE#0) ← *((const byte*) SPRITES_ENABLE#0) | (byte) processChars::bitmask#0
|
||||||
[220] *((const byte*) SCREEN#0+(const word) SPRITE_PTRS#0 + *((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_ID)) ← *((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_PTR)
|
[217] *((const byte*) SCREEN#0+(const word) SPRITE_PTRS#0 + *((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_ID)) ← *((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_PTR)
|
||||||
[221] *((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_STATUS) ← (const byte) STATUS_PROCESSING#0
|
[218] *((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_STATUS) ← (const byte) STATUS_PROCESSING#0
|
||||||
to:processChars::@3
|
to:processChars::@3
|
||||||
processChars::@3: scope:[processChars] from processChars::@10 processChars::@11
|
processChars::@3: scope:[processChars] from processChars::@10 processChars::@11
|
||||||
[222] (word) processChars::xpos#0 ← *((word*)(struct ProcessingSprite*) processChars::processing#0) >> (byte) 4
|
[219] (word) processChars::xpos#0 ← *((word*)(struct ProcessingSprite*) processChars::processing#0) >> (byte) 4
|
||||||
[223] (byte~) processChars::$12 ← > (word) processChars::xpos#0
|
[220] (byte~) processChars::$11 ← > (word) processChars::xpos#0
|
||||||
[224] if((byte) 0!=(byte~) processChars::$12) goto processChars::@4
|
[221] if((byte) 0!=(byte~) processChars::$11) goto processChars::@4
|
||||||
to:processChars::@8
|
to:processChars::@8
|
||||||
processChars::@8: scope:[processChars] from processChars::@3
|
processChars::@8: scope:[processChars] from processChars::@3
|
||||||
[225] (byte~) processChars::$13 ← (byte) $ff ^ (byte) processChars::bitmask#0
|
[222] (byte~) processChars::$12 ← (byte) $ff ^ (byte) processChars::bitmask#0
|
||||||
[226] *((const byte*) SPRITES_XMSB#0) ← *((const byte*) SPRITES_XMSB#0) & (byte~) processChars::$13
|
[223] *((const byte*) SPRITES_XMSB#0) ← *((const byte*) SPRITES_XMSB#0) & (byte~) processChars::$12
|
||||||
to:processChars::@5
|
to:processChars::@5
|
||||||
processChars::@5: scope:[processChars] from processChars::@4 processChars::@8
|
processChars::@5: scope:[processChars] from processChars::@4 processChars::@8
|
||||||
[227] (byte~) processChars::$18 ← (byte) processChars::i#10 << (byte) 1
|
[224] (byte~) processChars::$17 ← (byte) processChars::i#10 << (byte) 1
|
||||||
[228] (byte~) processChars::$15 ← (byte)(word) processChars::xpos#0
|
[225] (byte~) processChars::$14 ← (byte)(word) processChars::xpos#0
|
||||||
[229] *((const byte*) SPRITES_XPOS#0 + (byte~) processChars::$18) ← (byte~) processChars::$15
|
[226] *((const byte*) SPRITES_XPOS#0 + (byte~) processChars::$17) ← (byte~) processChars::$14
|
||||||
[230] (word~) processChars::$16 ← *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_Y) >> (byte) 4
|
[227] (word~) processChars::$15 ← *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_Y) >> (byte) 4
|
||||||
[231] (byte) processChars::ypos#0 ← (byte)(word~) processChars::$16
|
[228] (byte) processChars::ypos#0 ← (byte)(word~) processChars::$15
|
||||||
[232] *((const byte*) SPRITES_YPOS#0 + (byte~) processChars::$18) ← (byte) processChars::ypos#0
|
[229] *((const byte*) SPRITES_YPOS#0 + (byte~) processChars::$17) ← (byte) processChars::ypos#0
|
||||||
[233] if(*((word*)(struct ProcessingSprite*) processChars::processing#0)<(const word) XPOS_LEFTMOST#0) goto processChars::@6
|
[230] if(*((word*)(struct ProcessingSprite*) processChars::processing#0)<(const word) XPOS_LEFTMOST#0) goto processChars::@6
|
||||||
to:processChars::@15
|
|
||||||
processChars::@15: scope:[processChars] from processChars::@5
|
|
||||||
[234] if(*((word*)(struct ProcessingSprite*) processChars::processing#0)>(const word) XPOS_RIGHTMOST#0) goto processChars::@6
|
|
||||||
to:processChars::@14
|
to:processChars::@14
|
||||||
processChars::@14: scope:[processChars] from processChars::@15
|
processChars::@14: scope:[processChars] from processChars::@5
|
||||||
[235] if(*((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_Y)<(const word) YPOS_TOPMOST#0) goto processChars::@6
|
[231] if(*((word*)(struct ProcessingSprite*) processChars::processing#0)>(const word) XPOS_RIGHTMOST#0) goto processChars::@6
|
||||||
to:processChars::@13
|
to:processChars::@13
|
||||||
processChars::@13: scope:[processChars] from processChars::@14
|
processChars::@13: scope:[processChars] from processChars::@14
|
||||||
[236] if(*((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_Y)>(const word) YPOS_BOTTOMMOST#0) goto processChars::@6
|
[232] if(*((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_Y)<(const word) YPOS_TOPMOST#0) goto processChars::@6
|
||||||
|
to:processChars::@12
|
||||||
|
processChars::@12: scope:[processChars] from processChars::@13
|
||||||
|
[233] if(*((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_Y)>(const word) YPOS_BOTTOMMOST#0) goto processChars::@6
|
||||||
to:processChars::@9
|
to:processChars::@9
|
||||||
processChars::@9: scope:[processChars] from processChars::@13
|
processChars::@9: scope:[processChars] from processChars::@12
|
||||||
[237] (word~) processChars::$26 ← (word) processChars::xpos#0 >> (byte) 3
|
[234] (word~) processChars::$25 ← (word) processChars::xpos#0 >> (byte) 3
|
||||||
[238] (byte~) processChars::$27 ← (byte)(word~) processChars::$26
|
[235] (byte~) processChars::$26 ← (byte)(word~) processChars::$25
|
||||||
[239] (byte) processChars::xchar#0 ← (byte~) processChars::$27 - (const byte) BORDER_XPOS_LEFT#0/(byte) 8
|
[236] (byte) processChars::xchar#0 ← (byte~) processChars::$26 - (const byte) BORDER_XPOS_LEFT#0/(byte) 8
|
||||||
[240] (byte~) processChars::$37 ← (byte) processChars::xchar#0 << (byte) 1
|
[237] (byte~) processChars::$38 ← (byte) processChars::xchar#0 << (byte) 1
|
||||||
[241] *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_VX) ← *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_VX) + *((const word*) VXSIN#0 + (byte~) processChars::$37)
|
[238] *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_VX) ← *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_VX) + *((const word*) VXSIN#0 + (byte~) processChars::$38)
|
||||||
[242] *((word*)(struct ProcessingSprite*) processChars::processing#0) ← *((word*)(struct ProcessingSprite*) processChars::processing#0) + *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_VX)
|
[239] *((word*)(struct ProcessingSprite*) processChars::processing#0) ← *((word*)(struct ProcessingSprite*) processChars::processing#0) + *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_VX)
|
||||||
[243] (byte~) processChars::$31 ← (byte) processChars::ypos#0 >> (byte) 3
|
[240] (byte~) processChars::$30 ← (byte) processChars::ypos#0 >> (byte) 3
|
||||||
[244] (byte) processChars::ychar#0 ← (byte~) processChars::$31 - (const byte) BORDER_YPOS_TOP#0/(byte) 8
|
[241] (byte) processChars::ychar#0 ← (byte~) processChars::$30 - (const byte) BORDER_YPOS_TOP#0/(byte) 8
|
||||||
[245] (byte~) processChars::$38 ← (byte) processChars::ychar#0 << (byte) 1
|
[242] (byte~) processChars::$39 ← (byte) processChars::ychar#0 << (byte) 1
|
||||||
[246] *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_VY) ← *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_VY) + *((const word*) VYSIN#0 + (byte~) processChars::$38)
|
[243] *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_VY) ← *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_VY) + *((const word*) VYSIN#0 + (byte~) processChars::$39)
|
||||||
[247] *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_Y) ← *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_Y) + *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_VY)
|
[244] *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_Y) ← *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_Y) + *((word*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_VY)
|
||||||
to:processChars::@7
|
to:processChars::@7
|
||||||
processChars::@7: scope:[processChars] from processChars::@6 processChars::@9
|
processChars::@7: scope:[processChars] from processChars::@6 processChars::@9
|
||||||
[248] (byte) processChars::numActive#1 ← ++ (byte) processChars::numActive#10
|
[245] (byte) processChars::numActive#1 ← ++ (byte) processChars::numActive#10
|
||||||
to:processChars::@2
|
to:processChars::@2
|
||||||
processChars::@2: scope:[processChars] from processChars::@1 processChars::@7
|
processChars::@2: scope:[processChars] from processChars::@1 processChars::@7
|
||||||
[249] (byte) processChars::numActive#3 ← phi( processChars::@1/(byte) processChars::numActive#10 processChars::@7/(byte) processChars::numActive#1 )
|
[246] (byte) processChars::numActive#3 ← phi( processChars::@1/(byte) processChars::numActive#10 processChars::@7/(byte) processChars::numActive#1 )
|
||||||
[250] (byte) processChars::i#1 ← ++ (byte) processChars::i#10
|
[247] (byte) processChars::i#1 ← ++ (byte) processChars::i#10
|
||||||
[251] if((byte) processChars::i#1!=(const byte) NUM_PROCESSING#0-(byte) 1+(byte) 1) goto processChars::@1
|
[248] if((byte) processChars::i#1!=(const byte) NUM_PROCESSING#0-(byte) 1+(byte) 1) goto processChars::@1
|
||||||
to:processChars::@12
|
|
||||||
processChars::@12: scope:[processChars] from processChars::@2
|
|
||||||
[252] (byte~) processChars::$1 ← (byte) '0' + (byte) processChars::numActive#3
|
|
||||||
[253] *((const byte*) SCREEN#0+(word) $3e7) ← (byte~) processChars::$1
|
|
||||||
to:processChars::@return
|
to:processChars::@return
|
||||||
processChars::@return: scope:[processChars] from processChars::@12
|
processChars::@return: scope:[processChars] from processChars::@2
|
||||||
[254] return
|
[249] return
|
||||||
to:@return
|
to:@return
|
||||||
processChars::@6: scope:[processChars] from processChars::@13 processChars::@14 processChars::@15 processChars::@5
|
processChars::@6: scope:[processChars] from processChars::@12 processChars::@13 processChars::@14 processChars::@5
|
||||||
[255] *((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_STATUS) ← (const byte) STATUS_FREE#0
|
[250] *((byte*)(struct ProcessingSprite*) processChars::processing#0 + (const byte) OFFSET_STRUCT_PROCESSINGSPRITE_STATUS) ← (const byte) STATUS_FREE#0
|
||||||
[256] (byte~) processChars::$34 ← (byte) $ff ^ (byte) processChars::bitmask#0
|
[251] (byte~) processChars::$33 ← (byte) $ff ^ (byte) processChars::bitmask#0
|
||||||
[257] *((const byte*) SPRITES_ENABLE#0) ← *((const byte*) SPRITES_ENABLE#0) & (byte~) processChars::$34
|
[252] *((const byte*) SPRITES_ENABLE#0) ← *((const byte*) SPRITES_ENABLE#0) & (byte~) processChars::$33
|
||||||
to:processChars::@7
|
to:processChars::@7
|
||||||
processChars::@4: scope:[processChars] from processChars::@3
|
processChars::@4: scope:[processChars] from processChars::@3
|
||||||
[258] *((const byte*) SPRITES_XMSB#0) ← *((const byte*) SPRITES_XMSB#0) | (byte) processChars::bitmask#0
|
[253] *((const byte*) SPRITES_XMSB#0) ← *((const byte*) SPRITES_XMSB#0) | (byte) processChars::bitmask#0
|
||||||
to:processChars::@5
|
to:processChars::@5
|
||||||
irqTop: scope:[irqTop] from
|
irqTop: scope:[irqTop] from
|
||||||
[259] phi()
|
[254] phi()
|
||||||
to:irqTop::@1
|
to:irqTop::@1
|
||||||
irqTop::@1: scope:[irqTop] from irqTop irqTop::@1
|
irqTop::@1: scope:[irqTop] from irqTop
|
||||||
[260] (byte) irqTop::i#2 ← phi( irqTop/(byte) 0 irqTop::@1/(byte) irqTop::i#1 )
|
[255] *((const byte*) RASTER#0) ← (const byte) RASTER_IRQ_MIDDLE#0
|
||||||
[261] (byte) irqTop::i#1 ← ++ (byte) irqTop::i#2
|
[256] *((const void()**) HARDWARE_IRQ#0) ← &interrupt(HARDWARE_ALL)(void()) irqBottom()
|
||||||
[262] if((byte) irqTop::i#1!=(byte) 5) goto irqTop::@1
|
[257] *((const byte*) IRQ_STATUS#0) ← (const byte) IRQ_RASTER#0
|
||||||
to:irqTop::@2
|
|
||||||
irqTop::@2: scope:[irqTop] from irqTop::@1 irqTop::@2
|
|
||||||
[263] (byte) irqTop::i1#2 ← phi( irqTop::@1/(byte) 0 irqTop::@2/(byte) irqTop::i1#1 )
|
|
||||||
[264] (byte) irqTop::i1#1 ← ++ (byte) irqTop::i1#2
|
|
||||||
[265] if((byte) irqTop::i1#1!=(byte) 8) goto irqTop::@2
|
|
||||||
to:irqTop::@3
|
|
||||||
irqTop::@3: scope:[irqTop] from irqTop::@2
|
|
||||||
[266] *((const byte*) RASTER#0) ← (const byte) RASTER_IRQ_MIDDLE#0
|
|
||||||
[267] *((const void()**) HARDWARE_IRQ#0) ← &interrupt(HARDWARE_ALL)(void()) irqBottom()
|
|
||||||
[268] *((const byte*) IRQ_STATUS#0) ← (const byte) IRQ_RASTER#0
|
|
||||||
to:irqTop::@return
|
to:irqTop::@return
|
||||||
irqTop::@return: scope:[irqTop] from irqTop::@3
|
irqTop::@return: scope:[irqTop] from irqTop::@1
|
||||||
[269] return
|
[258] return
|
||||||
to:@return
|
to:@return
|
File diff suppressed because it is too large
Load Diff
@ -2,6 +2,9 @@
|
|||||||
(label) @2
|
(label) @2
|
||||||
(label) @begin
|
(label) @begin
|
||||||
(label) @end
|
(label) @end
|
||||||
|
(byte*) BGCOL
|
||||||
|
(byte) BLUE
|
||||||
|
(byte*) BORDERCOL
|
||||||
(byte) BORDER_XPOS_LEFT
|
(byte) BORDER_XPOS_LEFT
|
||||||
(const byte) BORDER_XPOS_LEFT#0 BORDER_XPOS_LEFT = (byte) $18
|
(const byte) BORDER_XPOS_LEFT#0 BORDER_XPOS_LEFT = (byte) $18
|
||||||
(word) BORDER_XPOS_RIGHT
|
(word) BORDER_XPOS_RIGHT
|
||||||
@ -18,6 +21,7 @@
|
|||||||
(const byte) CIA_INTERRUPT_CLEAR#0 CIA_INTERRUPT_CLEAR = (byte) $7f
|
(const byte) CIA_INTERRUPT_CLEAR#0 CIA_INTERRUPT_CLEAR = (byte) $7f
|
||||||
(byte*) COLS
|
(byte*) COLS
|
||||||
(const byte*) COLS#0 COLS = (byte*) 55296
|
(const byte*) COLS#0 COLS = (byte*) 55296
|
||||||
|
(bool) DEBUG
|
||||||
(void()**) HARDWARE_IRQ
|
(void()**) HARDWARE_IRQ
|
||||||
(const void()**) HARDWARE_IRQ#0 HARDWARE_IRQ = (void()**) 65534
|
(const void()**) HARDWARE_IRQ#0 HARDWARE_IRQ = (void()**) 65534
|
||||||
(byte*) IRQ_ENABLE
|
(byte*) IRQ_ENABLE
|
||||||
@ -108,6 +112,7 @@
|
|||||||
(const word*) VXSIN#0 VXSIN = (word*) 8704
|
(const word*) VXSIN#0 VXSIN = (word*) 8704
|
||||||
(word*) VYSIN
|
(word*) VYSIN
|
||||||
(const word*) VYSIN#0 VYSIN = (word*) 8832
|
(const word*) VYSIN#0 VYSIN = (word*) 8832
|
||||||
|
(byte) WHITE
|
||||||
(word) XPOS_LEFTMOST
|
(word) XPOS_LEFTMOST
|
||||||
(const word) XPOS_LEFTMOST#0 XPOS_LEFTMOST = (word)(const byte) BORDER_XPOS_LEFT#0-(byte) 8<<(byte) 4
|
(const word) XPOS_LEFTMOST#0 XPOS_LEFTMOST = (word)(const byte) BORDER_XPOS_LEFT#0-(byte) 8<<(byte) 4
|
||||||
(word) XPOS_RIGHTMOST
|
(word) XPOS_RIGHTMOST
|
||||||
@ -218,22 +223,13 @@
|
|||||||
interrupt(HARDWARE_ALL)(void()) irqBottom()
|
interrupt(HARDWARE_ALL)(void()) irqBottom()
|
||||||
(label) irqBottom::@1
|
(label) irqBottom::@1
|
||||||
(label) irqBottom::@2
|
(label) irqBottom::@2
|
||||||
(label) irqBottom::@3
|
|
||||||
(label) irqBottom::@return
|
(label) irqBottom::@return
|
||||||
(byte) irqBottom::i
|
(byte) irqBottom::i
|
||||||
(byte) irqBottom::i#1 reg byte x 16.5
|
|
||||||
(byte) irqBottom::i#2 reg byte x 22.0
|
|
||||||
interrupt(HARDWARE_ALL)(void()) irqTop()
|
interrupt(HARDWARE_ALL)(void()) irqTop()
|
||||||
(label) irqTop::@1
|
(label) irqTop::@1
|
||||||
(label) irqTop::@2
|
|
||||||
(label) irqTop::@3
|
|
||||||
(label) irqTop::@return
|
(label) irqTop::@return
|
||||||
(byte) irqTop::i
|
(byte) irqTop::i
|
||||||
(byte) irqTop::i#1 reg byte x 16.5
|
|
||||||
(byte) irqTop::i#2 reg byte x 22.0
|
|
||||||
(byte) irqTop::i1
|
(byte) irqTop::i1
|
||||||
(byte) irqTop::i1#1 reg byte x 16.5
|
|
||||||
(byte) irqTop::i1#2 reg byte x 22.0
|
|
||||||
(void()) main()
|
(void()) main()
|
||||||
(byte~) main::$16 reg byte x 12.375
|
(byte~) main::$16 reg byte x 12.375
|
||||||
(byte) main::$25 reg byte a 22.0
|
(byte) main::$25 reg byte a 22.0
|
||||||
@ -293,29 +289,27 @@ interrupt(HARDWARE_ALL)(void()) irqTop()
|
|||||||
(word) mul8u::return#2 return zp ZP_WORD:26 22.0
|
(word) mul8u::return#2 return zp ZP_WORD:26 22.0
|
||||||
(word) mul8u::return#3 return zp ZP_WORD:26 22.0
|
(word) mul8u::return#3 return zp ZP_WORD:26 22.0
|
||||||
(void()) processChars()
|
(void()) processChars()
|
||||||
(byte~) processChars::$1 reg byte x 4.0
|
(byte~) processChars::$11 reg byte a 22.0
|
||||||
(byte~) processChars::$12 reg byte a 22.0
|
(byte~) processChars::$12 reg byte a 22.0
|
||||||
(byte~) processChars::$13 reg byte a 22.0
|
(byte~) processChars::$14 reg byte a 22.0
|
||||||
(byte~) processChars::$15 reg byte a 22.0
|
(word~) processChars::$15 $15 zp ZP_WORD:56 11.0
|
||||||
(word~) processChars::$16 $16 zp ZP_WORD:56 11.0
|
(byte~) processChars::$17 reg byte x 6.6000000000000005
|
||||||
(byte~) processChars::$18 reg byte x 6.6000000000000005
|
(word~) processChars::$25 $25 zp ZP_WORD:54 11.0
|
||||||
(word~) processChars::$26 $26 zp ZP_WORD:54 11.0
|
(byte~) processChars::$26 reg byte a 22.0
|
||||||
(byte~) processChars::$27 reg byte a 22.0
|
(byte~) processChars::$30 reg byte a 22.0
|
||||||
(byte~) processChars::$31 reg byte a 22.0
|
(byte~) processChars::$33 reg byte a 22.0
|
||||||
(byte~) processChars::$34 reg byte a 22.0
|
|
||||||
(byte~) processChars::$36 reg byte a 22.0
|
|
||||||
(byte~) processChars::$37 reg byte a 22.0
|
(byte~) processChars::$37 reg byte a 22.0
|
||||||
(byte~) processChars::$38 reg byte a 22.0
|
(byte~) processChars::$38 reg byte a 22.0
|
||||||
(byte) processChars::$64 reg byte a 22.0
|
(byte~) processChars::$39 reg byte a 22.0
|
||||||
(byte) processChars::$65 reg byte a 22.0
|
(byte) processChars::$65 reg byte a 22.0
|
||||||
(byte) processChars::$66 reg byte a 22.0
|
(byte) processChars::$66 reg byte a 22.0
|
||||||
|
(byte) processChars::$67 reg byte a 22.0
|
||||||
(label) processChars::@1
|
(label) processChars::@1
|
||||||
(label) processChars::@10
|
(label) processChars::@10
|
||||||
(label) processChars::@11
|
(label) processChars::@11
|
||||||
(label) processChars::@12
|
(label) processChars::@12
|
||||||
(label) processChars::@13
|
(label) processChars::@13
|
||||||
(label) processChars::@14
|
(label) processChars::@14
|
||||||
(label) processChars::@15
|
|
||||||
(label) processChars::@2
|
(label) processChars::@2
|
||||||
(label) processChars::@3
|
(label) processChars::@3
|
||||||
(label) processChars::@4
|
(label) processChars::@4
|
||||||
@ -333,7 +327,7 @@ interrupt(HARDWARE_ALL)(void()) irqTop()
|
|||||||
(byte) processChars::numActive
|
(byte) processChars::numActive
|
||||||
(byte) processChars::numActive#1 numActive zp ZP_BYTE:31 22.0
|
(byte) processChars::numActive#1 numActive zp ZP_BYTE:31 22.0
|
||||||
(byte) processChars::numActive#10 numActive zp ZP_BYTE:31 0.7674418604651163
|
(byte) processChars::numActive#10 numActive zp ZP_BYTE:31 0.7674418604651163
|
||||||
(byte) processChars::numActive#3 numActive zp ZP_BYTE:31 11.666666666666666
|
(byte) processChars::numActive#3 numActive zp ZP_BYTE:31 11.0
|
||||||
(struct ProcessingSprite*) processChars::processing
|
(struct ProcessingSprite*) processChars::processing
|
||||||
(struct ProcessingSprite*) processChars::processing#0 processing zp ZP_WORD:51 0.3235294117647059
|
(struct ProcessingSprite*) processChars::processing#0 processing zp ZP_WORD:51 0.3235294117647059
|
||||||
(byte) processChars::xchar
|
(byte) processChars::xchar
|
||||||
@ -450,11 +444,8 @@ reg byte a [ mul8u::b#0 ]
|
|||||||
reg byte x [ mul8u::a#3 mul8u::a#6 mul8u::a#2 mul8u::a#1 mul8u::a#0 ]
|
reg byte x [ mul8u::a#3 mul8u::a#6 mul8u::a#2 mul8u::a#1 mul8u::a#0 ]
|
||||||
zp ZP_WORD:26 [ mul8u::res#2 mul8u::res#6 mul8u::res#1 mul8u::return#2 mul8u::return#3 initSquareTables::$6 initSquareTables::$14 ]
|
zp ZP_WORD:26 [ mul8u::res#2 mul8u::res#6 mul8u::res#1 mul8u::return#2 mul8u::return#3 initSquareTables::$6 initSquareTables::$14 ]
|
||||||
zp ZP_WORD:28 [ mul8u::mb#2 mul8u::mb#0 mul8u::mb#1 ]
|
zp ZP_WORD:28 [ mul8u::mb#2 mul8u::mb#0 mul8u::mb#1 ]
|
||||||
reg byte x [ irqBottom::i#2 irqBottom::i#1 ]
|
|
||||||
zp ZP_BYTE:30 [ processChars::i#10 processChars::i#1 ]
|
zp ZP_BYTE:30 [ processChars::i#10 processChars::i#1 ]
|
||||||
zp ZP_BYTE:31 [ processChars::numActive#10 processChars::numActive#3 processChars::numActive#1 ]
|
zp ZP_BYTE:31 [ processChars::numActive#10 processChars::numActive#3 processChars::numActive#1 ]
|
||||||
reg byte x [ irqTop::i#2 irqTop::i#1 ]
|
|
||||||
reg byte x [ irqTop::i1#2 irqTop::i1#1 ]
|
|
||||||
reg byte a [ main::$25 ]
|
reg byte a [ main::$25 ]
|
||||||
reg byte a [ main::$26 ]
|
reg byte a [ main::$26 ]
|
||||||
reg byte a [ main::$27 ]
|
reg byte a [ main::$27 ]
|
||||||
@ -489,24 +480,23 @@ zp ZP_WORD:49 [ getCharToProcess::$15 ]
|
|||||||
reg byte a [ initSquareTables::$16 ]
|
reg byte a [ initSquareTables::$16 ]
|
||||||
reg byte a [ initSquareTables::$17 ]
|
reg byte a [ initSquareTables::$17 ]
|
||||||
reg byte a [ mul8u::$1 ]
|
reg byte a [ mul8u::$1 ]
|
||||||
reg byte a [ processChars::$64 ]
|
|
||||||
reg byte a [ processChars::$65 ]
|
reg byte a [ processChars::$65 ]
|
||||||
reg byte a [ processChars::$66 ]
|
reg byte a [ processChars::$66 ]
|
||||||
reg byte a [ processChars::$36 ]
|
reg byte a [ processChars::$67 ]
|
||||||
|
reg byte a [ processChars::$37 ]
|
||||||
zp ZP_WORD:51 [ processChars::processing#0 ]
|
zp ZP_WORD:51 [ processChars::processing#0 ]
|
||||||
zp ZP_BYTE:53 [ processChars::bitmask#0 ]
|
zp ZP_BYTE:53 [ processChars::bitmask#0 ]
|
||||||
zp ZP_WORD:54 [ processChars::xpos#0 processChars::$26 ]
|
zp ZP_WORD:54 [ processChars::xpos#0 processChars::$25 ]
|
||||||
|
reg byte a [ processChars::$11 ]
|
||||||
reg byte a [ processChars::$12 ]
|
reg byte a [ processChars::$12 ]
|
||||||
reg byte a [ processChars::$13 ]
|
reg byte x [ processChars::$17 ]
|
||||||
reg byte x [ processChars::$18 ]
|
reg byte a [ processChars::$14 ]
|
||||||
reg byte a [ processChars::$15 ]
|
zp ZP_WORD:56 [ processChars::$15 ]
|
||||||
zp ZP_WORD:56 [ processChars::$16 ]
|
|
||||||
zp ZP_BYTE:58 [ processChars::ypos#0 ]
|
zp ZP_BYTE:58 [ processChars::ypos#0 ]
|
||||||
reg byte a [ processChars::$27 ]
|
reg byte a [ processChars::$26 ]
|
||||||
reg byte a [ processChars::xchar#0 ]
|
reg byte a [ processChars::xchar#0 ]
|
||||||
reg byte a [ processChars::$37 ]
|
|
||||||
reg byte a [ processChars::$31 ]
|
|
||||||
reg byte a [ processChars::ychar#0 ]
|
|
||||||
reg byte a [ processChars::$38 ]
|
reg byte a [ processChars::$38 ]
|
||||||
reg byte x [ processChars::$1 ]
|
reg byte a [ processChars::$30 ]
|
||||||
reg byte a [ processChars::$34 ]
|
reg byte a [ processChars::ychar#0 ]
|
||||||
|
reg byte a [ processChars::$39 ]
|
||||||
|
reg byte a [ processChars::$33 ]
|
Loading…
Reference in New Issue
Block a user