dschmenk / PLASMA

Proto Language AsSeMbler for All (formerly Apple)
MIT License
191 stars 26 forks source link

Incorrect branch in Apple ][ SAW implementation #36

Closed ZornsLemma closed 6 years ago

ZornsLemma commented 6 years ago

Hi Dave,

Congratulations on v1.0! (And thanks for your kind mention in the docs!) I'm taking a look at updating my Acorn port and I've noticed a possible bug in plvm02.s's SAW implementation. It ends with:

        BMI     +
        JMP     DROP
        JMP     FIXDROP

Shouldn't there be a leading '+' on the final line? As I read this that BMI will branch to the next '+' label inside ISGE:

+       BPL     ISFLS
        BMI     ISTRU

which won't do the right thing.

Cheers.

Steve

dschmenk commented 6 years ago

Once again, you have the eagle eye. Thanks!