arc: Use negative enter pattern instruction's offsets
authorClaudiu Zissulescu <claziss@gmail.com>
Mon, 10 Oct 2022 07:27:12 +0000 (10:27 +0300)
committerClaudiu Zissulescu <claziss@gmail.com>
Mon, 10 Oct 2022 07:32:32 +0000 (10:32 +0300)
commit5e81df88cae713bf867c6260df79994d59cac5e5
tree161fef272825bee8cdce98d02f2648d3495182ac
parentdecbb5bf7cc7317fefa53f0d64082cf020e85e42
arc: Use negative enter pattern instruction's offsets

The enter pattern instruction contains the necessary information for
the dwarf machinery to generate the appropriate dwarf code.  This
patch is fixing the register offsets related to CFA, and adds a test.

gcc/
* config/arc/arc.cc (arc_save_callee_enter): Use negative offsets.

gcc/testsuite
* gcc.target/arc/enter-dw2-1.c: New file.

Signed-off-by: Claudiu Zissulescu <claziss@gmail.com>
gcc/config/arc/arc.cc
gcc/testsuite/gcc.target/arc/enter-dw2-1.c [new file with mode: 0644]