Re: [patch] Do not generate discriminator directive in strict mode

2011-04-20 Thread Richard Henderson
On 04/20/2011 12:09 PM, Eric Botcazou wrote: >> How is this not redundant with the existing >> >> /* The discriminator column was added in dwarf4. Simplify the below >> by simply removing it if we're not supposed to output it. */ >> if (dwarf_version < 4 && dwarf_strict) >> discrimin

Re: [patch] Do not generate discriminator directive in strict mode

2011-04-20 Thread Eric Botcazou
> How is this not redundant with the existing > > /* The discriminator column was added in dwarf4. Simplify the below > by simply removing it if we're not supposed to output it. */ > if (dwarf_version < 4 && dwarf_strict) > discriminator = 0; > > check near the top of the function?

Re: [patch] Do not generate discriminator directive in strict mode

2011-04-20 Thread Richard Henderson
On 04/19/2011 06:40 AM, Eric Botcazou wrote: > - if (SUPPORTS_DISCRIMINATOR && discriminator != 0) > + if (SUPPORTS_DISCRIMINATOR > + && discriminator != 0 > + && (dwarf_version >= 4 || !dwarf_strict)) > fprintf (asm_out_file, " discriminator %d", discriminator); How is

[patch] Do not generate discriminator directive in strict mode

2011-04-19 Thread Eric Botcazou
Hi, it appears that the (standard DWARF as of version 4) discriminator directive can confuse non-GDB DWARF 2/3 debuggers, so this patch changes the compiler to stop emitting it in strict mode. Tested on i586-suse-linux, OK for the mainline? 2011-04-19 Eric Botcazou * dwarf2out.c (