... too many ideas and too little time ... Related stuff written in Python:
Dragon 32 emulator / PyDC - Python Dragon 32 converter: https://github.com/jedie/DragonPy
DWLOAD server / Dragon-Lib and other stuff: https://github.com/6809
These are overflow cases leading to value, which can't expressed 16 bit quotient/remainder. So the overflow condition is - in this actual implemention - flagged by a remainder with value 0xFFFF, beside this, the quotient value is meaningless.
As far as I can see (checked it on a 6502 Forth) - this USLASH implementation is mainly for Forth environments - the quotient (top of stack) is expected to return 0xFFFF (or -1 as signed integer) where the remainder has the value of the divisor.
I will change the implementation towards this to keep the various Forth implementations consistent.
These are overflow cases leading to value, which can't expressed 16 bit quotient/remainder. So the overflow condition is - in this actual implemention - flagged by a remainder with value 0xFFFF, beside this, the quotient value is meaningless.
As far as I can see (checked it on a 6502 Forth) - this USLASH implementation is mainly for Forth environments - the quotient (top of stack) is expected to return 0xFFFF (or -1 as signed integer) where the remainder has the value of the divisor.
I will change the implementation towards this to keep the various Forth implementations consistent.
Fixed it know, see https://github.com/6809/sbc09/blob/usla ... uslash.asm
Quotient = 0xFFFF and remainder = 0x0000 marks a division by zero, hence the result is undefined
A remainder > 0 if the quotient is 0xFFFF is just an overflow.
... too many ideas and too little time ... Related stuff written in Python:
Dragon 32 emulator / PyDC - Python Dragon 32 converter: https://github.com/jedie/DragonPy
DWLOAD server / Dragon-Lib and other stuff: https://github.com/6809
Exist there somewhere a small assembler prgramm, that used the SEX and MUL Instructions?
... too many ideas and too little time ... Related stuff written in Python:
Dragon 32 emulator / PyDC - Python Dragon 32 converter: https://github.com/jedie/DragonPy
DWLOAD server / Dragon-Lib and other stuff: https://github.com/6809
... too many ideas and too little time ... Related stuff written in Python:
Dragon 32 emulator / PyDC - Python Dragon 32 converter: https://github.com/jedie/DragonPy
DWLOAD server / Dragon-Lib and other stuff: https://github.com/6809