[llvm-commits] [llvm] r37940 - in /llvm/trunk: include/llvm/CodeGen/SelectionDAGNodes.h include/llvm/ParameterAttributes.h lib/AsmParser/Lexer.l lib/AsmParser/llvmAsmParser.y lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp lib/Target/TargetCallingC

Chris Lattner clattner at apple.com
Tue Jul 17 08:37:01 PDT 2007


On Jul 17, 2007, at 2:58 AM, Rafael Espindola wrote:

>> I actually don't like this approach, because this depends a lot of
>> decisions made in the code generator: the copy may be in registers
>> (hopefully) or on the stack, or with some magic funny thing.  Adding
>> an extra copy at the llvm level would require the codegen to remove
>> it, which is really hard.
>
> No, the idea is that all the frame allocation and manipulation would
> be done in the FE. So, from a BE point of view, all arguments would be
> on registers. For example, when compiling C on a i686 all resulting
> llvm functions would hove only one argument (the frame pointer).
>
> Again, this would be a massive change. For the current bug I believe
> that the "byval" proposal is much easier to implement.

The problem is that not all "byval" structs get passed in registers.   
On x86-32 for example, they all get passed on the stack, just a very  
"specific" part of the stack.  I like the current byval proposal :)

-Chris



More information about the llvm-commits mailing list