> I will admit to sometimes using some of the BCD
instructions in the
> 80x86 family, such as AAM, DAA, etc. 'course, other than my sales tax
> program, I usually use them for stuff other than BCD.
On Mon, 24 Oct 2011, Chuck Guzis wrote:
It's still hard to beat COBOL for money-handling.
I would not have been able to make a 4K TSR for calculating California
sales tax based on ZIPCODE, using COBOL. Few people can write machine
language in COBOL.
When I had to write a Windoze version, size was no longer a major
constraint, so I wrote it in C (scaled ints, NO "float"!), and played
games with the linker/binder to make an .EXE that would run in Windoze,
but would load the 4K TSR if it was launched in DOS. (Hint: using the
Microsoft "examples", look at STUB.EXE) I intended, but didn't get around
to, modifying it further, so that the same .EXE could also be run/loaded
as a fake device driver by CONFIG.SYS to load the TSR lower in RAM to be
able to be able to use INTRA-segment pointers to the BIOS data area (for
easier keyboard buffer access)
COBOL was tempting for the Windoze executable.
My USUAL uses for the BCD arithmetic codes (DAA, AAM, etc.) are STILL
mostly for decimal/ASCII, hexadecimal/ASCII conversions (without a
conditional jump!).