diff options
author | Alexandre Oliva <oliva@adacore.com> | 2024-05-29 02:52:07 -0300 |
---|---|---|
committer | Alexandre Oliva <oliva@gnu.org> | 2024-06-07 02:09:23 -0300 |
commit | 3472b5749df53b91bcb00a3e82cc85ef1f3b17ce (patch) | |
tree | 9c4d412918beaf08da85d4923d362b42d421948e /gcc/target.def | |
parent | b24f2954dbc13d85e9fb62e05a88e9df21e4d4f4 (diff) | |
download | gcc-3472b5749df53b91bcb00a3e82cc85ef1f3b17ce.zip gcc-3472b5749df53b91bcb00a3e82cc85ef1f3b17ce.tar.gz gcc-3472b5749df53b91bcb00a3e82cc85ef1f3b17ce.tar.bz2 |
enable adjustment of return_pc debug attrs
This patch introduces infrastructure for targets to add an offset to
the label issued after the call_insn to set the call_return_pc
attribute. This will be used on rs6000, that sometimes issues another
instruction after the call proper as part of a call insn.
for gcc/ChangeLog
* target.def (call_offset_return_label): New hook.
* doc/tm.texi.in (TARGET_CALL_OFFSET_RETURN_LABEL): Add
placeholder.
* doc/tm.texi: Rebuild.
* dwarf2out.cc (struct call_arg_loc_node): Record call_insn
instead of call_arg_loc_note.
(add_AT_lbl_id): Add optional offset argument.
(gen_call_site_die): Compute and pass on a return pc offset.
(gen_subprogram_die): Move call_arg_loc_note computation...
(dwarf2out_var_location): ... from here. Set call_insn.
Diffstat (limited to 'gcc/target.def')
-rw-r--r-- | gcc/target.def | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/gcc/target.def b/gcc/target.def index c27df80..70070ca 100644 --- a/gcc/target.def +++ b/gcc/target.def @@ -4891,6 +4891,15 @@ Most ports do not need to implement anything for this hook.", hook_void_CUMULATIVE_ARGS) DEFHOOK +(call_offset_return_label, + "While generating call-site debug info for a CALL insn, or a SEQUENCE\n\ +insn starting with a CALL, this target hook is invoked to compute the\n\ +offset to be added to the debug label emitted after the call to obtain\n\ +the return address that should be recorded as the return PC.", + int, (rtx_insn *call_insn), + hook_int_rtx_insn_0) + +DEFHOOK (push_argument, "This target hook returns @code{true} if push instructions will be\n\ used to pass outgoing arguments. When the push instruction usage is\n\ |