Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Data.Macaw.PPC: finish block when link register equals the IP
To ensure that PC-relative reads are classified properly, the disassembler needs to (prematurely) end a block when the IP is the same as the link register. Normally, a `bl` instruction to the next address is not considered a terminal statement (contrary to what is described in the previous commit). Without this change, a pc-relative load followed by a direct jump would be erroneously classifed as a function call (that returns to where the pc-relative load happens), since the call classifier defines a call as any jump where the link register has been modified. This change handles this exact pattern by ensuring that the link register update ends the block, preventing subsequent direct jumps from deciding that the link register has been modified and classifying them as calls.
- Loading branch information