[all-commits] [llvm/llvm-project] d20c54: [LoongArch] Override TargetFrameLowering::spillCal...
wanglei via All-commits
all-commits at lists.llvm.org
Thu Nov 10 05:15:20 PST 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: d20c54cbdb9a4a12bbfb1d51c72e52abd3f039a6
https://github.com/llvm/llvm-project/commit/d20c54cbdb9a4a12bbfb1d51c72e52abd3f039a6
Author: wanglei <wanglei at loongson.cn>
Date: 2022-11-10 (Thu, 10 Nov 2022)
Changed paths:
M llvm/lib/Target/LoongArch/LoongArchFrameLowering.cpp
M llvm/lib/Target/LoongArch/LoongArchFrameLowering.h
A llvm/test/CodeGen/LoongArch/spill-ra-without-kill.ll
Log Message:
-----------
[LoongArch] Override TargetFrameLowering::spillCalleeSavedRegisters
When using `llvm.returnaddress` intrinsic, special handling is required
for the spill of the `RA` register. Otherwise it will cause the verifier
fail in some cases (e.g. pr17377.c of the GCC C Torture Suite).
Specifically:
```
*** Bad machine code: Using an undefined physical register ***
- function: f
- basic block: %bb.0 entry (0xd94d18)
- instruction: ST_D killed $r1, $r22, -40 :: (store (s64) into %stack.2)
- operand 0: killed $r1
```
Reviewed By: SixWeining
Differential Revision: https://reviews.llvm.org/D137387
More information about the All-commits
mailing list