[PATCH] D74225: [AIX] Implement formal arguments passed in stack memory

Chris Bowler via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 24 08:49:21 PST 2020


cebowleratibm added inline comments.


================
Comment at: llvm/lib/Target/PowerPC/PPCISelLowering.cpp:6852
+                                  : CCValAssign::LocInfo::ZExt;
     if (unsigned Reg = State.AllocateReg(IsPPC64 ? GPR_64 : GPR_32)) {
       State.addLoc(CCValAssign::getReg(ValNo, ValVT, Reg, RegVT, LocInfo));
----------------
Braces are no longer necessary.


================
Comment at: llvm/lib/Target/PowerPC/PPCISelLowering.cpp:6857
       State.addLoc(CCValAssign::getMem(ValNo, ValVT, Offset, RegVT, LocInfo));
-
+    
     return false;
----------------
trailing whitespace.


================
Comment at: llvm/lib/Target/PowerPC/PPCISelLowering.cpp:7009
+
+    // Get the extended size of the argument type in stack.
+    const unsigned LocSize = LocVT.getStoreSize();
----------------
I don't feel that this comment adds to understanding the code.  I suggest removing it.


================
Comment at: llvm/lib/Target/PowerPC/PPCISelLowering.cpp:7011
+    const unsigned LocSize = LocVT.getStoreSize();
+    // Get the actual size of the argument type.
+    const unsigned ValSize = ValVT.getStoreSize();
----------------
I don't feel that this comment adds to understanding the code. I suggest removing it.


================
Comment at: llvm/lib/Target/PowerPC/PPCISelLowering.cpp:7019
+    if ((LocSize > ValSize) && IsPPC64)
+        CurArgOffset += LocSize - ValSize;
+    MachineFrameInfo &MFI = MF.getFrameInfo();
----------------
formatting.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D74225/new/

https://reviews.llvm.org/D74225





More information about the llvm-commits mailing list