For PowerPCs how do you find out the TOC address or the SDA address? Like for example in this case.
1 Answer
SDA
is r13
, and it changes very rarely. So finding any assignment to r13 will solve the problem for SDA.
Specifically for the referred example it was
lis r13, 1 # Load Immediate Shifted
addi r13, r13, -0x2BF0 # 0xD410 # Add Immediate
-
-
-
Thank you. I noticed more r2 loading references than r13 which is clearly one or 2 maximum. I would assume it should be also nearby? Is this the Global TOC right ?– amgnetCommented Dec 22, 2016 at 7:17