You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently the default inline hook shim process seems to be:
Original instruction
move LR into R0
store LR and r3-31 to a stack frame as usual
jump
steps 2 & 3 in reverse.
However, this pattern means that if we hook an instruction (or series of instructions) that is using r0, we won't save that value. I think ideally we would also put the original r0 value into the stack frame that we are generating. I think the added safety is likely worth the 4 bytes, but I'd be interested to hear your take on this.
The text was updated successfully, but these errors were encountered:
Will be fixed in the next version. Although this does bring up some deeper questions about the way we are doing hooks. I am going to revisit the hooking system soon and see if there is any room for optimization.
Currently the default inline hook shim process seems to be:
However, this pattern means that if we hook an instruction (or series of instructions) that is using r0, we won't save that value. I think ideally we would also put the original r0 value into the stack frame that we are generating. I think the added safety is likely worth the 4 bytes, but I'd be interested to hear your take on this.
The text was updated successfully, but these errors were encountered: