[AArch64] Fix save register pairing for Windows AAPCS
authorSanne Wouda <Sanne.Wouda@arm.com>
Tue, 14 Jan 2020 13:16:57 +0000 (13:16 +0000)
committerSanne Wouda <Sanne.Wouda@arm.com>
Tue, 14 Jan 2020 15:08:27 +0000 (15:08 +0000)
commit1cc8fff420a76ae869f73ce2b19e7c1fc73da3ed
treee83e909e205dac988c60e3bb445fbaf978406d58
parent192cce10f67e4f22be6d9b8c0975f78ad246d1bd
[AArch64] Fix save register pairing for Windows AAPCS

Summary:
On Windows, when a function does not have an unwind table (for example, EH
filtering funclets), we don't correctly pair FP and LR to form the frame record
in all circumstances.

Fix this by invalidating a pair when the second register is FP when compiling
for Windows, even when CFI is not needed.

Fixes PR44271 introduced by D65653.

Reviewers: efriedma, sdesmalen, rovka, rengolin, t.p.northover, thegameg, greened

Reviewed By: rengolin

Subscribers: kristof.beyls, hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D71754
llvm/lib/Target/AArch64/AArch64FrameLowering.cpp
llvm/test/CodeGen/AArch64/win64-no-uwtable.ll [new file with mode: 0644]