[PATCH] D70800: Fix AArch64 AAPCS frame record chain

Logan Chien via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 2 21:54:24 PST 2019


logan marked 4 inline comments as done.
logan added inline comments.


================
Comment at: llvm/lib/Target/AArch64/AArch64FrameLowering.cpp:1022
     // Only set up FP if we actually need to.
-    int FPOffset = isTargetDarwin(MF) ? (AFI->getCalleeSavedStackSize() - 16) : 0;
+    int FPOffset = isTargetDarwin(MF) ? (AFI->getCalleeSavedStackSize() - 16)
+                                      : AFI->getFrameRecordOffset();
----------------
sdesmalen wrote:
> Having calculated the offset to the FrameRecord explicitly, can we now replace this with:
>   int FPOffset = AFI->getFrameRecordOffset();
> ?
Yes.  Replaced in the latest Diff.


================
Comment at: llvm/lib/Target/AArch64/AArch64MachineFunctionInfo.h:129
 
+  // Offset from SP-at-entry to frame record (i.e. the spilled frame pointer
+  // and link address).
----------------
sdesmalen wrote:
> Is this description correct? The current meaning of `FrameRecordOffset` seems to be the offset from SP _after_ allocating the callee-save area.
Thanks.  Reworded.


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

https://reviews.llvm.org/D70800





More information about the llvm-commits mailing list