[AArch64][SVE] Fix calculation restore point for SVE callee saves.
authorSander de Smalen <sander.desmalen@arm.com>
Wed, 19 Aug 2020 10:06:51 +0000 (11:06 +0100)
committerSander de Smalen <sander.desmalen@arm.com>
Wed, 26 Aug 2020 09:02:31 +0000 (10:02 +0100)
commit5f47d4456d192eaea8c56a2b4648023c8743c927
tree86b2d8535090822e7c3da233d4f1e7d20eb36aae
parentf22d27624b6532a5542b283de9ce586c72c6b846
[AArch64][SVE] Fix calculation restore point for SVE callee saves.

This fixes an issue where the restore point of callee-saves in the
function epilogues was incorrectly calculated when the basic block
consisted of only a RET instruction. This caused dealloc instructions
to be inserted in between the block of callee-save restore instructions,
rather than before it.

Reviewed By: paulwalker-arm

Differential Revision: https://reviews.llvm.org/D86099
llvm/lib/Target/AArch64/AArch64FrameLowering.cpp
llvm/test/CodeGen/AArch64/framelayout-sve-calleesaves-fix.mir [new file with mode: 0644]