mirror of https://github.com/PCSX2/pcsx2.git
Detect and skip padding nops at the end of functions
This commit is contained in:
parent
7a20d94536
commit
0ade0a44b5
|
@ -115,6 +115,11 @@ namespace MIPSAnalyst
|
|||
}
|
||||
*/
|
||||
if (end) {
|
||||
// most functions are aligned to 8 or 16 bytes
|
||||
// add the padding to this one
|
||||
while (r5900Debug.read32(addr+8) == 0)
|
||||
addr += 4;
|
||||
|
||||
currentFunction.end = addr + 4;
|
||||
currentFunction.isStraightLeaf = isStraightLeaf;
|
||||
functions.push_back(currentFunction);
|
||||
|
@ -123,6 +128,7 @@ namespace MIPSAnalyst
|
|||
looking = false;
|
||||
end = false;
|
||||
isStraightLeaf = true;
|
||||
|
||||
currentFunction.start = addr+4;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue