[prev in list] [next in list] [prev in thread] [next in thread] 

List:       binutils
Subject:    Re: [PATCH] nios2: Don't disable relaxation with --gdwarf-N
From:       Sandra Loosemore <sandra () codesourcery ! com>
Date:       2021-01-26 16:16:33
Message-ID: 28c51da1-5b11-ebb2-2806-4422db80cf53 () codesourcery ! com
[Download RAW message or body]

On 1/26/21 5:51 AM, H.J. Lu wrote:
> On Mon, Jan 25, 2021 at 1:19 PM H.J. Lu <hjl.tools@gmail.com> wrote:
>>
>> After
>>
>> commit 705989f19adf20dd70c50237ec61cd708f2b0939
>> Author: H.J. Lu <hjl.tools@gmail.com>
>> Date:   Mon Jan 18 06:25:05 2021 -0800
>>
>>      as: Automatically enable DWARF5 support
>>
>> --gdwarf-5 is no longer needed to accept DWARF5 info generated by GCC.
>>
>> Since assembler generated debug information is incompatible with
>> relaxation, don't generate debug information for assembly codes with
>> --gdwarf-5 which is passed down by GCC.
>>
>> OK for master and 2.36 branch?
>>
>> H.J.
>> ---
>>          PR gas/27243
>>          * config/tc-nios2.c (md_begin): Set debug_type to DEBUG_UNSPECIFIED
>>          for --gdwarf-5.
>>          * testsuite/gas/nios2/relax.d: New file.
>>          * testsuite/gas/nios2/relax.s: Likewise.
> 
> GCC 11 passes --gdwarf-5 to assembler to enable DWARF5 debug info.  Don't
> disable relaxation when --gdwarf-N is specified.  The assembler generated
> debug information will treat the sequence of the relaxed instructions as
> a single instruction.
> 
> OK for master and 2.36 branch?

This is OK.  I tested the same tweak overnight, gas and gcc test results 
look reasonable with no Dwarf-related failures, and I also convinced 
myself through manual inspection that the line number table is being 
adjusted properly for the relaxation code sequences.

-Sandra
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic