[LLVMdev] How to check if an Instruction is still in a Function

Bill Wendling wendling at apple.com
Mon Mar 1 16:29:41 PST 2010


On Feb 28, 2010, at 11:11 AM, Jianzhou Zhao wrote:

> Hi,
> 
> Given an instruction ptr instr, and a Function ptr func,
> can I simply check if func == instr->get_parent()->get_parent() to see if
> this instruction is still in this Function?
> 
Yup!

-bw




More information about the llvm-dev mailing list