erichkeane marked 3 inline comments as done.
erichkeane added a comment.

patch incoming



================
Comment at: include/clang/CodeGen/CGFunctionInfo.h:139
+    AI.setInReg(true);
+    AI.setCanBeFlattened(false);
+    return AI;
----------------
rnk wrote:
> In the long run, I think ABIArgInfo::Direct is too overloaded and needs to be 
> split. The implementation of a single direct argument in EmitFunctionPrologue 
> is *174* lines. It would be much cleaner to make some new ABIArgInfo types 
> instead of having these "can be flattened" flags and things.
I think you're right, this was my first run-in with what "direct" means and it 
took a lot to figure out what it even MEANS.  I definitely think that it is 
worth a refactoring in the future.  I notice that a lot of the ABIArgInfo 
/ABIInfo related things could strongly benefit from a refactoring as well.


================
Comment at: lib/CodeGen/TargetInfo.cpp:1507
-       State.CC == llvm::CallingConv::X86_RegCall) &&
-      isHomogeneousAggregate(Ty, Base, NumElts)) {
-    if (State.FreeSSERegs >= NumElts) {
----------------
rnk wrote:
> You don't seem to do anything in this if block if !IsHva, so maybe fold it 
> back into the initial check like it was, and then break out the case for 
> regcall and vectorcall separately.
I did this same thing in 2 places, so I suspect I had SOME /*good*/ reason for 
splitting it out like this, but I cannot for the life of me remember it.  
Changed.


https://reviews.llvm.org/D27529



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to