new version
authorTobias Girstmair <tobi@isticktoit.net>
Thu, 4 Mar 2021 22:30:05 +0000 (23:30 +0100)
committerTobias Girstmair <tobi@isticktoit.net>
Thu, 4 Mar 2021 22:30:05 +0000 (23:30 +0100)
bsv.c

diff --git a/bsv.c b/bsv.c
index c7533ef71e2c9922bb29513b3e75c5e30cb65b8a..411bede5123c9c9f460a2c6e9bfbb9b146a9e922 100644 (file)
--- a/bsv.c
+++ b/bsv.c
@@ -55,9 +55,8 @@ void g(void){
        /*T0SN  FLAG.Z (0x00.0)*/       if(3&i2) {// skip if !(3&i0)
        SET1    (notes_ix, 3)           } // ix += 8 <=> ix |= 8
        IDXM    (acc, notes+notes_ix)
-       u8 result = ((i1<<8|i0)*acc)>>8;  // keep hi byte
-       //^TODO! https://git.gir.st/Chiptunes.git/blob/d397f89:/foo.c#l83
-       //final: https://git.gir.st/Chiptunes.git/blob/f8e0502:/foo.S#l113
+
+       //unrolled: https://git.gir.st/Chiptunes.git/blob/f8e0502:/foo.S#l113
        u8 a2 = 0; // can probably be overloaded onto mul3lo/hi
        u8 a1 = 0; // -"-
        u8 t  = acc; // note input (as returned by idxm)
@@ -72,7 +71,7 @@ void g(void){
        skip:   SR      (a2)
                SRC     (a1)
        }
-       acc = a1;
+       MOV     (acc, a1)
 }
 void main(void){
        CLEAR   (i0)
Imprint / Impressum