The Disassembly window displays memory content as PDP-11 opcodes. A few opcodes before and after an interesting code address are disassembled. The code address is highlighted in the produced code.

 

pdp11gui_disassembly

You just enter an address and press  “Examine”. The Disassembler window is read-only. The disassembler interprets everything as opcodes and can not recognize embedded data. I used the disassembly module from http://ftp.rodents.montreal.qc.ca/mouse/pdp11/ .

The disassembly window is updated on these events:

  • If the “Examine” button is pressed
  • If one of the displayed memory locations is changed by another tool window. So you can enter octal values for a particular memory location in a Memory window, and immediately check the resulting opcodes in the Disassembly window.
  • If program execution is halted or Reset or Single Step was performed in the Execution window.

You will see in Terminal window that memory content is fetched with regular Examine commands.

All addresses are 16 bit virtual addresses.

Single Step, Code cache and self modifying code

Every time the Disassembly window is updated, it examines a block of adresses around the code address from the target machine. Since the disassembly window is typically used to trace program execution while stepping through code with “Single step”, this can cause significant overhead on slow connections.

So an optional code cache can be used:
Then only those addresses are fetched from the target machine that were not visible on the last Update. This is a great optimization for “Single Step” since the code address changes only slightly between update.

On the other hand, the code cache is unusable if code is self-modifiying: code changes will not show up in the Disassembly window, if they occur in cached code addresses.