[PATCH] D72454: [AIX] Enable frame pointer for AIX and add related test suite
Zarko Todorovski via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jan 10 07:05:54 PST 2020
ZarkoCA added inline comments.
Herald added a subscriber: wuzish.
================
Comment at: llvm/lib/Target/PowerPC/PPCFrameLowering.cpp:63
static unsigned computeFramePointerSaveOffset(const PPCSubtarget &STI) {
// For the Darwin ABI:
// We cannot use the TOC save slot (offset +20) in the PowerPC linkage area
----------------
The comment talks about the Darwin ABI but it looks that part of the code is removed. Should the comment be edited or am I misunderstanding?
================
Comment at: llvm/lib/Target/PowerPC/PPCSubtarget.h:301
+ // the red zone. The stack floor is at 220 bytes for 32-bit mode and 288
+ // bytes for 64-bit mode lower than the stack pointer.
+ // [32-bit mode]
----------------
Can this be rewritten to:
`On the AIX ABI, the scratch area is called the stack floor as opposed to the red zone. The stack floor is 220 bytes lower than the stack pointer in 32-bit mode and 288 bytes lower in 64-bit mode`? Does this capture the same meaning?
================
Comment at: llvm/test/CodeGen/PowerPC/Frames-alloca.ll:2
+; RUN: llc < %s -mtriple=powerpc-unknown-linux-gnu | FileCheck %s -check-prefix=PPC32-LINUX
+; RUN: llc < %s -mtriple=powerpc64-unknown-linux-gnu | FileCheck %s -check-prefix=PPC64-LINUX
+; RUN: llc < %s -mtriple=powerpc-unknown-linux-gnu -frame-pointer=all | FileCheck %s -check-prefix=PPC32-LINUX
----------------
Is this testing the 64-bit ELFV1 ABI or the 64-bit ELFV2 ABI? Basically I'm asking whether this should be `powerpc64le-unknown-linux-gnu` or is this ok?
================
Comment at: llvm/test/CodeGen/PowerPC/Frames-alloca.ll:39
+; - Frame pointer register (r31) is saved/defined/restored.
+; - Allocated area is referrd by frame pointer with correct offset.
+; - Allocated area is 4 bytes aligned in the case of int.
----------------
typo: should be `referred`, this happens in other test cases below
================
Comment at: llvm/test/CodeGen/PowerPC/aix-frames-alloca-with-func-call.ll:47
+
+CHECK: LLVM ERROR: Handling of placing parameters on the stack is unimplemented!
----------------
Thanks for including this test in this form. We can update it once we enable this.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D72454/new/
https://reviews.llvm.org/D72454
More information about the llvm-commits
mailing list