Table of Contents
Early mid October work
2023-10-15
This week mostly involved updates to the Extension for lDebug system.
insref NOT fix
The instruction reference wrongly claimed that the NOT instruction changed the arithmetic status flags. This is not true. I fixed that, and in the same section added that NEG behaves as if subtracting from zero. I heard that NOT not changing flags was on oversight during the design of the 8086.
The least obvious and most notable case is that NOT doesn't affect FLAGS, apparently a design mistake by Stephen Morse when specifying the 8086 ISA. All the other standard ALU instructions that date back to 8086 affect at least some FLAGS, except for LEA which is sort of special.Peter Cordes, in a comment 2022-11-07 04:10:36Z, License: CC BY-SA 4.0
One Boolean instruction, NOT, is missing from the list of Boolean instructions that affect the flags. NOT does not affect the flags. This was a result of an oversight (I goofed!) when the processor was being defined.Steve Morse, The 8086/8088 Primer, page 98
TracList & tractest
The documentation got an update to list that the TracList option --local-offset disables the default offsets. This bit me as adding the switch manually for ELD debugging disabled tracing the debugger listing, which needs an offset of zero.
The other changes concern passing along (and handling as a "line") and reading a hint called TracList-add-offset= which can be used to add file-local (or global) offsets to a running TracList. This is to be used for debugging ELDs that may be loaded to any offset within the ELD code section.
symscr
One of the symbolic debugging scripts got updated to make it more usable for sending commands to a serial terminal connected to a debugger. sendser.pl now accepts a –bytesleep= switch specifying how long to sleep before sending each byte. A value of "0.01" seconds (equivalent to 10 milliseconds) is used in some examples, allowing 100 Bytes per second.
lDebug
Changes not specific to ELDs
- Document the variable set up parameter and result uses of CH register
- Fix build with _CATCHINT2D=0
- Fix build with _CATCHINT2D=0 _AREAS_HOOK_SERVER=1 (by disabling the areas server)
- Enable new NASM warnings (as errors) for section-crossing relative relocations, as requested by me originally in 2019
- Add _DX option to enable or disable DX command independently of _PM option
ELD infrastructure
- Hook AMIS interface, allowing to add AMIS functions in the 40h to 4Fh range (reserved for ELD extension functions) and monitor/change all AMIS functions
- DOS input is no longer required to load ELDs, only DOS being available (not InDOS)
- Add function
intcall_extfor use by ELDs
ELD linker and architecture
- Add
source/eld/ovr.shto hg ignored files - Display hint to another debugger using a new AMIS function to announce the offset an ELD loads at, with the listing filename used
- Do not write to CS selector
- Check name length limit of links
- Optimise away optional code links support in the linker and links tables if not used by an ELD
- Allow to change the
relocateddatavstart, including setting it to zero to optimise the linker by one instruction - Fix bugs found from new vstart change option
- Add comments with test install and test run commands, as well as scriptlets to write eldcomp commands based on them to a serial terminal (in the changeset messages)
Specific ELD changes
- amount: Fix DI return in variable set up
- eldcomp: Add additional pass with sufficiently sized buffers allocated to save the differing ELD sections, eventually running a C command to compare them
- eldcomp: Install a
putshandler to add ELD in-section offsets display to C command output - eldcomp: Also observe
NOFREEONESHOTDCO7 - testamis: Test ELD to hook AMIS interface, with special handling to use an ID to differentiate multiple resident instances of the same ELD
- amismsg: ELD to receive a message on AMIS interface (function 40h) and display it to the debugger terminal using an inject handler. This is used to get the trace offset hint from an ELD linker to an outer debugger, which will display it for tractest to receive.
- amismsg: New AMIS function 41h to query whether there is still a message not yet displayed
- variable: magic, fix pointer arithmetic
- history: Fix missing
NOFREEONESHOTDCO7 test - amismsg: Add AMISMSG DISPLAY command to repeat last message that is still buffered
