[LLVMdev] Stack Management in LLVM

Joshua Moore-Oliva llvm-dev at chatgris.com
Thu Jul 23 16:06:12 PDT 2009

If I could reduce my requirements to the ability to the following:
    * Ability to know how much stack space a function requires
    * Move the stack pointer arbitrarily (the ability to write my own function 
prologue and epilogue, would need to be able to insert assembly/low level 
code here) before and after a method call

could LLVM do that for me, using the system stack, (not continuations with 
malloc)?  Or am I barking up the wrong tree with this tool?

Thanks, Josh

On July 17, 2009 12:42:23 am Eli Friedman wrote:
> On Thu, Jul 16, 2009 at 9:29 PM, Joshua
> Moore-Oliva<llvm-dev at chatgris.com> wrote:
> > To the list of modifications I need to be able to perform, add
> >
> > the ability to specify the ordering of local variables in the stack
> If you need specific locations for everything you're allocating on the
> stack, you should probably just use a continuation-passing style like
> the one mentioned in
> http://nondot.org/sabre/LLVMNotes/ExplicitlyManagedStackFrames.txt ;
> LLVM won't preserve the values of variables allocated with alloca
> whose address isn't taken.
> -Eli
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev

More information about the llvm-dev mailing list