[LLVMdev] how to code a loop in llvm assembly

Carl Friedrich Bolz cfbolz at gmx.de
Sat Apr 15 13:12:48 PDT 2006


Patrick Meredith wrote:
> Using an alloca'd variable with loads and stores would work well  too.  
> To date this
> is how every llvm language front end works.

nope :-). PyPy produces SSA code diretly when using the LLVM backend, 
which is not surprising, since PyPy uses SSA internally.

> You would want to avoid  malloc for
> such a purpose generally.  mem2reg is nice enough to take your local  load
> and stores and promote them to registers with PHINodes :-)

Cheers,

Carl Friedrich Bolz




More information about the llvm-dev mailing list