[LLVMdev] how to get the address of operand
John Criswell
criswell at cs.uiuc.edu
Tue Oct 30 19:52:01 PDT 2007
Keoncheol Shin wrote:
> Hi,
> I tried to write code transformation pass using LLVM.
> But I couldn’t find how to get the address of some operand (i.e. ‘&’ operation in C).
> If an integer type variable is generated by AllocaInst(), is there any method to get the address of that variable?
>
The LLVM alloca instruction allocates memory on the stack. The SSA
value that the alloca generates is a pointer to the integer on the stack.
-- John T.
> Thanks,
> Keoncheol
>
>
>
More information about the llvm-dev
mailing list