On 2012-07-31 15:51, DJ Delorie wrote:
>> I don't see that 4.6 requires a different patch.
> 
> 4.6 is missing this:
> 
> 2011-04-01  Richard Henderson  <r...@redhat.com>
> 
>       PR 48400
>       * dwarf2out.c (dwarf2out_source_line): Disable discriminators
>       in strict mode before dwarf4.  Re-order tests to early out
>       before switching sections.
> 
> So either *that* patch needs to be back-ported, or the tpf-specific
> workaround does.
> 

In 4.6 we do not emit discriminators except with DWARF2_ASM_LINE_DEBUG_INFO,
and in that section we have

          if (SUPPORTS_DISCRIMINATOR && discriminator != 0
              && (dwarf_version >= 4 || !dwarf_strict))
            fprintf (asm_out_file, " discriminator %d", discriminator);

and sure enough dwarf_strict is honored.

That patch is only required if you have the other patches that introduce
discriminators to the non-dwarf2_asm_line path.


r~

Reply via email to