]> git.ipfire.org Git - thirdparty/gcc.git/commit
riscv: xtheadmempair: Fix CFA reg notes
authorChristoph Müllner <christoph.muellner@vrull.eu>
Mon, 24 Apr 2023 21:09:06 +0000 (23:09 +0200)
committerKito Cheng <kito.cheng@sifive.com>
Wed, 12 Jul 2023 08:05:50 +0000 (16:05 +0800)
commit93973e4c5d3bcde1f84cad3b42a8c36e23900d19
tree1f8362461b4e77dd902ed13f1e6277558fbf0274
parentd05c8b016fb96cdcc445406469867b757776894e
riscv: xtheadmempair: Fix CFA reg notes

The current implementation triggers an assertion in
dwarf2out_frame_debug_cfa_offset() under certain circumstances.
The standard code uses REG_FRAME_RELATED_EXPR notes instead
of REG_CFA_OFFSET notes when saving registers on the stack.
So let's do this as well.

gcc/ChangeLog:

* config/riscv/thead.cc (th_mempair_save_regs):
Emit REG_FRAME_RELATED_EXPR notes in prologue.

Signed-off-by: Christoph Müllner <christoph.muellner@vrull.eu>
gcc/config/riscv/thead.cc