-
Notifications
You must be signed in to change notification settings - Fork 14
Description
While having the symbol list in the breakpoint dropdown in the code stepper is very useful, it only catches labels that were both (1) exported and (2) used by another module, as it uses the linker output mapfile. The mapfile does not list local ("cheap") and anonymous labels used as a jump target. The disassembly window is relatively small and sometimes doesn't show the "important" parts of a function, which may be after a significant number of internal branches or (per cc65) a large number of subroutine calls. Finding the "important" parts is relegated to reading disassembly lists, which are difficult outside of the emulator (da65 ignores all after the first 64kbyte). My present workflow has been to look at the addresses in the disassembler and set breakpoints on them before continuing, which involves typing an address from memory, interacting with a small subdialog, and clicking two buttons ("OK", then "Continue"). As a result, I end up with a large number of address-only, oft-disabled breakpoints that I often have to delete all at once when code shifts due to a new version.
I'm proposing temporary breakpoints, wherein a breakpoint on a certain PC exists only until it is triggered; it is then automatically removed after pausing, and is not synchronized with the per-ROM config. This has two use cases:
- "Step over" can then be implemented as follows: only if the instruction at the PC is
JSR(or--optionally--if an NMI or IRQ is pending and enabled), set a temporary breakpoint for the following instruction (3 bytes away in theJSRcase) and continue instead. Otherwise, step as usual. - Using the mouse, one could, for example, click on the list item in the disassembly containing a line of interest (perhaps only on its address, to reserve clicks elsewhere for other features). This should set a temporary breakpoint at that address, then continue. This would suffice in areas where a subroutine isn't involved, like a long branch loop.
Those points can be follow-up issues to the main impetus of this issue, if desired.