ghidra
ghidra copied to clipboard
6805: JSR calls include erroneous write references to the stack
Describe the bug
When double-clicking the target in a JSR
(jump subroutine) instruction's target operand, an Operand References window appears, showing a reference to the stack (address 0xFE
) and one to the target function/subroutine.
This doesn't happen on other processor types; it causes a usability issue where functions are harder to follow. Ideally the stack write should be hidden in some way, or otherwise ignored by Ghidra.
To Reproduce Steps to reproduce the behavior:
- Disassemble a binary for the 6805 which includes
JSR
(e.g.CD 05 B8
opcode) andRTS
(XX
opcode) instructions. - Scroll down to a
JSR
instruction and double click the target operand. - Note that the References screen pops up, showing a write to the stack address, and the target jump.
- See error
Expected behavior Same behaviour as other processor types; stack pushes/pops are not included in the reference list, and function calls can simply be double-clicked to follow them to the target.
Screenshots
Environment (please complete the following information):
- OS: Linux Mint 21.3 "Virginia"
- Java Version: 17.0.10
- Ghidra Version: 11.1 DEV, 2024-Feb-23
- Ghidra Origin: Locally built from Git HEAD