[Bug target/44189] PIC compilation on ARM screws up DWARF lineinfo in function prologue

gergely+gccbug at risko dot hu gcc-bugzilla@gcc.gnu.org
Fri May 21 08:07:00 GMT 2010



------- Comment #2 from gergely+gccbug at risko dot hu  2010-05-21 08:06 -------
Based on code in cfgexpand.c (search for start_locus), my patch
should probably use something like this for setting the location:
              /* Eventually, all FEs should explicitly set
function_start_locus.  */
              if (cfun->function_start_locus == UNKNOWN_LOCATION)
                set_curr_insn_source_location
                  (DECL_SOURCE_LOCATION (current_function_decl));
              else
                set_curr_insn_source_location (cfun->function_start_locus);

I am not sure if there are still frontends that do not set
function_start_locus.

And probably this functionality should be moved to a function and we should
only call that function from two places.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44189



More information about the Gcc-bugs mailing list