[LLVMdev] conditionally reduced intrinsics (llvm.syscall)
Chris Lattner
sabre at nondot.org
Sun Aug 22 18:58:29 PDT 2004
On Sun, 22 Aug 2004, Brian R. Gaeke wrote:
> > Well, the complexity only occurs on x86, other archs are simpler. Since
> > this is not used much outside the c library, I can work around it in the
> > library and be satisifed with the simple case.
>
> Architecture-specific calling conventions are typically dealt with
> in the various target support libraries (lib/Target/*).
>
> I think what you should do for the X86 codegen is to use the
> MachineFrameInfo to build your memory block and add the >6 case
> "directly to the codegen", as you say. I recommend against inserting
> MachineInstrs that explicitly manipulate the stack pointer; you are
> likely to fall afoul of the PrologEpilogInserter and register
> allocator.
A good way to figure out how to do this is to look at the code that is
generated for the alloca instruction in the X86 backend.
-Chris
--
http://llvm.org/
http://nondot.org/sabre/
More information about the llvm-dev
mailing list