Reset prologue_location before calling code_end
authorBernd Edlinger <bernd.edlinger@hotmail.de>
Sat, 8 May 2021 05:46:17 +0000 (07:46 +0200)
committerBernd Edlinger <bernd.edlinger@hotmail.de>
Mon, 10 May 2021 06:18:03 +0000 (08:18 +0200)
Some targets emit thunks from the targetm.asm_out.code_end
function and set the DECL_IGNORED_P, but due to
e69ac020372 ("Add line debug info for virtual thunks")
the value in prologue_location is no longer ignored.

So reset that value before calling the backend.

2021-05-10  Bernd Edlinger  <bernd.edlinger@hotmail.de>

PR middle-end/100467
* toplev.c (compile_file): Call insn_locations_init before
targetm.asm_out.code_end.

gcc/toplev.c

index d8cc254..7e23253 100644 (file)
@@ -523,6 +523,7 @@ compile_file (void)
 
       /* This must be at the end before unwind and debug info.
         Some target ports emit PIC setup thunks here.  */
+      insn_locations_init ();
       targetm.asm_out.code_end ();
 
       /* Do dbx symbols.  */