User Tools

Site Tools


blog:pushbx:2026:0921_mid_september_work_on_the_debugger_symbolic_option_ident86

Mid September work on the debugger, symbolic option, ident86

2026-09-20

Of note, I finally added three subrepos to the lDebug repo, namely lmacros, scanptab, and symsnip. This allows the makefiles to properly reference the source text files in these subrepos as dependencies.

symsnip

ETA:

  • Identicalise a jump (between -f obj and -f bin builds) by chaining to another conditional jump. (This jump's distance was close to the rel8 limit, which appears to cause differing behaviour from NASM for the two builds.)

lmacros

  • Add a third parameter to lpar, which can be needframe or notneedframe. The latter doesn't define the lpar label and allows to omit the frame setup if lframe_needonlyregistered is used. This is useful for using lret with a calculated imm16 to the retn or retf instruction, but without accessing the frame at any point. Used for the restore_scratchsel shim function for _PM=0 builds.

lDebug (experimental)

ETA:

ident86

I'm working on the identicalisation program to help on comparing the -f bin and -f obj builds of lDebug. The dualcall and nearcall mmacros need to handle their trailing word as word-sized data rather than instructions. Long dispatch tables need to handle their data as words even if the first difference in a range happens to fall in the continued machine code dump line (so that the found offset points to this continued line rather than the first line).

ETA:

                    if firstdifference - int(args.offset, 0) >= newoffset_line + newamount:
                        continue
                    if newoffset_line > firstdifference - int(args.offset, 0):
                        continue

This only falls through if firstdifference is below the end of this machine code dump and above-or-equal the beginning of this machine code dump. Assuming a well-formed trace listing file, a more exact match will not be found later on, so the search might as well stop here.

Privately, I have indicated that I don't always understand ident86 intricacies. I've likened this to "vibe coding" minus the generative AI, going by my own vibes. Someone suggested calling this "evolutionary coding", with "no idea of what you're doing, just testing if it works and moving on". I'm not proud of that but as long as my attempts aren't futile permanently, it does get the job done.

You could leave a comment if you were logged in.
blog/pushbx/2026/0921_mid_september_work_on_the_debugger_symbolic_option_ident86.txt · Last modified: by ecm