Displaying 1 result from an estimated 1 matches for "aa71006f".
2018 Sep 05
3
How to get return address at llvm ir level?
Hi
I want to write a FunctionPass to insert some code before return.
Funcion:
..
..
..
mov eax,[esp]
cmp eax,0x12345678
je 0x12345678
ret
(maybe stack will not balance)
I wonder that can I get the return address at llvm ir level?
I use IRBuilder to CreateICmpEQ and CreateCondBr.
but I don't how to get the value of return addrss.
I have found there is a Intrinsic::returnaddress.
Is