From a1d0e5bb65ccce3063111eb903c0a9edfcad2627 Mon Sep 17 00:00:00 2001 From: Irmen de Jong Date: Wed, 13 Sep 2023 21:51:48 +0200 Subject: [PATCH] added list of software to docs --- .../cpu6502/assignment/AssignmentAsmGen.kt | 5 --- docs/source/index.rst | 1 + docs/source/software.rst | 34 +++++++++++++++++++ docs/source/todo.rst | 4 --- examples/cx16/plasma.p8 | 9 ++--- 5 files changed, 40 insertions(+), 13 deletions(-) create mode 100644 docs/source/software.rst diff --git a/codeGenCpu6502/src/prog8/codegen/cpu6502/assignment/AssignmentAsmGen.kt b/codeGenCpu6502/src/prog8/codegen/cpu6502/assignment/AssignmentAsmGen.kt index efd076840..ef2df9b37 100644 --- a/codeGenCpu6502/src/prog8/codegen/cpu6502/assignment/AssignmentAsmGen.kt +++ b/codeGenCpu6502/src/prog8/codegen/cpu6502/assignment/AssignmentAsmGen.kt @@ -1538,11 +1538,6 @@ internal class AssignmentAsmGen(private val program: PtProgram, } private fun attemptAssignToByteCompareZero(expr: PtBinaryExpression, assign: AsmAssignment): Boolean { - // TODO optimized code for (word1 & word2) == 0 : -// if(expr.left.type in WordDatatypes && (expr.operator=="==" || expr.operator=="!=") && expr.left is PtBinaryExpression) { -// println("TODO optimize logical word expr ${expr.position}") -// } - when (expr.operator) { "==" -> { when(val dt = expr.left.type) { diff --git a/docs/source/index.rst b/docs/source/index.rst index 579d715aa..7033192d5 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -201,6 +201,7 @@ Look in the `syntax-files `_ available in the source code repository, +there are also larger pieces of software written using Prog8. Here's a list. + + +`Assembler `_ + File-based assembler for the Commander X16. + +`Chess `_ + Chess game for the Commander X16, with 2-player or computer opponent game modes. + +`Image viewer `_ + Multi-format image viewer for the Commander X16. + Can display C64 Koala, BMP, PCX and Amiga IFF images, including color cycling. + +`Petaxian `_ + Galaga type shoot em up game using only petscii graphics. Runs on C64 and Commander X16. + +`Rock Runner `_ + Faithful Boulderdash clone, a well known arcade puzzle game from the 80's. + where you must collect all diamonds in a level while avoiding the hazards to reach the exit. + Can load the thousands of available fan made level files. + This game is for the Commander X16. + +`Shell `_ + Unix like command shell for the Commander X16. + +`Streaming Music Demo `_ + Demoscene like "music demos" for the Commander X16. + They display graphics, animated song lyrics, and play a high quality sampled song streamed from disk. diff --git a/docs/source/todo.rst b/docs/source/todo.rst index 2e0a396b4..742fdf76c 100644 --- a/docs/source/todo.rst +++ b/docs/source/todo.rst @@ -1,10 +1,6 @@ TODO ==== -- possibly optimize assembly output for (word1 & word2 ==0) - see attemptAssignToByteCompareZero() for assignment. - see testZeroOrJumpElsewhere() for if condition. - - [on branch: shortcircuit] investigate McCarthy evaluation again? this may also reduce code size perhaps for things like if a>4 or a<2 .... - IR: reduce the number of branch instructions such as BEQ, BEQR, etc (gradually), replace with CMP(I) + status branch instruction - IR: reduce amount of CMP/CMPI after instructions that set the status bits correctly (LOADs? INC? etc), but only after setting the status bits is verified! diff --git a/examples/cx16/plasma.p8 b/examples/cx16/plasma.p8 index 1339e469e..a156ba7ef 100644 --- a/examples/cx16/plasma.p8 +++ b/examples/cx16/plasma.p8 @@ -25,6 +25,7 @@ main { cbm.SETTIM(0,0,0) while cbm.GETIN()==0 { + ; sys.waitvsync() doplasma() frames ++ } @@ -64,15 +65,15 @@ main { for y in 0 to txt.DEFAULT_HEIGHT-1 { ybuf[y] = math.sin8u(c1a) + math.sin8u(c1b) - c1a += 4 - c1b += 9 + c1a += 2 + c1b += 5 } c1A += 3 c1B -= 5 for x in 0 to txt.DEFAULT_WIDTH-1 { xbuf[x] = math.sin8u(c2a) + math.sin8u(c2b) - c2a += 3 - c2b += 7 + c2a += 4 + c2b += 1 } c2A += 2 c2B -= 3