mirror of
https://github.com/ksherlock/x65.git
synced 2025-02-06 09:29:57 +00:00
Minor disassembler annoyances addressing
- Label ranges outside of data would be ignored for instructions - If last code reference was a jump table then its references would get stripped
This commit is contained in:
parent
fd46f1aa1a
commit
7902863ccc
@ -1715,7 +1715,7 @@ void GetReferences(unsigned char *mem, size_t bytes, bool acc_16, bool ind_16, i
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
last--;
|
last--;
|
||||||
if (last<=1 || refs[last].data==DT_CODE)
|
if (last<=1 || (refs[last].data==DT_CODE || refs[last].data==DT_PTRS))
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2114,7 +2114,7 @@ void Disassemble(strref filename, unsigned char *mem, size_t bytes, bool acc_16,
|
|||||||
strown<64> lblname;
|
strown<64> lblname;
|
||||||
strref lblcmt;
|
strref lblcmt;
|
||||||
for (size_t i = 0; i<refs.size(); ++i) {
|
for (size_t i = 0; i<refs.size(); ++i) {
|
||||||
if (reference == refs[i].address ||
|
if (reference == refs[i].address || (reference>=refs[i].address && reference<(refs[i].address+refs[i].size)) ||
|
||||||
(reference>=start_addr && reference<=end_addr && reference>=refs[i].address)) {
|
(reference>=start_addr && reference<=end_addr && reference>=refs[i].address)) {
|
||||||
if (i==(refs.size()-1) || reference<refs[i+1].address) {
|
if (i==(refs.size()-1) || reference<refs[i+1].address) {
|
||||||
RefAddr &ra = refs[i];
|
RefAddr &ra = refs[i];
|
||||||
|
Loading…
x
Reference in New Issue
Block a user