OSDN Git Service

[AArch64] Break the dependency between FP and SP when possible.
authorChad Rosier <mcrosier@codeaurora.org>
Mon, 14 Mar 2016 18:17:41 +0000 (18:17 +0000)
committerChad Rosier <mcrosier@codeaurora.org>
Mon, 14 Mar 2016 18:17:41 +0000 (18:17 +0000)
commit4005bceb12e71ef0c4df21f585a373006654bfc1
treea12b12e5872031d159d61af3cd4b23f9e19cdc1a
parentb7448a08ddabc64dbcb7c0f60d2d43db0e586ca9
[AArch64] Break the dependency between FP and SP when possible.

When the SP in not changed because of realignment/VLAs etc., we restore the SP
by using the previous value of SP and not the FP. Breaking the dependency will
help in cases when the epilog of a callee is close to the epilog of the caller;
for then "sub sp, fp, #" depends on the load restoring the FP in the epilog of
the callee.

http://reviews.llvm.org/D18060
Patch by Aditya Kumar and Evandro Menezes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@263458 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/AArch64/AArch64FrameLowering.cpp
lib/Target/AArch64/AArch64MachineFunctionInfo.h
test/CodeGen/AArch64/arm64-hello.ll
test/CodeGen/AArch64/arm64-patchpoint.ll
test/CodeGen/AArch64/arm64-shrink-wrapping.ll
test/CodeGen/AArch64/fastcc.ll