On Wed, 8 Mar 2017 14:32:10 -0600, John McKown wrote: >> >> AP goes right to left because it would otherwise have to do more work to >> propagate carry. > >​Right. But it could go to the left if the nybbles in the packed decimal >number were in reverse order, with the sign nybble being the first >(leftmost) nybble in the data stream. I.e. instead of 01234F be F43210 . >But that was likely not acceptable because one reason that programmers love >packed rather than binary is that they can read it directly in the hex >dump. Said dump being far more prevalent tool for debugging in the far >past. Some decisions are not really hardware dictated. They're cultural. > DFP must have been a great disappointment to programmers who expected it would facilitate reading floating point numbers in dumps.
And appearance of dumps is the only reason I can imagine that packed decimal is sign-magnitude rather than 10's complement. o 10's complement would allow a greater range in the same storage. E.g. -5000 to +4999 rather than -999 to +999 in two bytes. o 10's complement would obviate the need for a recomplement pass half the time when adding numbers with unlike signs. Once I saw a VAX dump. The ASCII read left-to-right. The hex had the higher addresses on the left, so it read as if big-endian. I.e. where the ASCII showed ABCD; the hex showed 44434241. -- gil ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN
