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 _______________________________________________ llvm-commits mailing list llvm-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits