Decimal V Binary??
Tom Jennings
tomj at wps.com
Sun Oct 10 00:02:18 CDT 2004
On Sun, 10 Oct 2004, der Mouse wrote:
> >> I've always wondered what systems/processors (other than IBM
> >> mainframes) that had hardware decimal arithmetic support.
>
> The VAX has packed decimal arithmetic instructions. Depending on which
> VAX, they may be microcoded or they may just trap to the OS for
> "macrocoded" emulation (of course the OS may choose to error out
> instead of bothering).
The lowly 8080 had DAA, Decimal Adjust for Addition. If I recall,
it handled "carry" from bit5 (and Cy?) after adding a BCD pair
in A.
Man, I wrote a lot of 8080 code, so much I still remember
opcodes and could puzzle out binary 20 years later, but it's
possible I never once used DAA. Hell, I used MOV A, A even.
(An inline pseudo-disassembler; a config file could specify
the IO port a tape drive interface was located and the program
modified itself to change all the port numbers for IN and
OUT. IO instructions following MOV A, A were modified.)
More information about the cctalk
mailing list