On 09/20/2017 02:31 AM, Jakub Jelinek wrote: > On Wed, Sep 20, 2017 at 10:20:03AM +0200, Richard Biener wrote: >> Anyway, I did a quick LTO bootstrap with your patch and it seems >> to work fine. >> >> Can you add a testcase verifying -gdwarf-5 works ok (properly >> emitting a debug_line_str section?). > > I'm afraid I can't. We don't have a command line switch for > DWARF2_ASM_LINE_DEBUG_INFO, it is something tested solely at configure time > (I've noticed this because my working directory for whatever reason > (many hundreds of reconfigures) doesn't have this defined), and we actually > emit > proper DWARF5 .debug_line{,_str} only in that case; when using .file > directives, it is waiting for missing binutils support. > > Perhaps we should add -fno-dwarf2-loc-asm to force emitting .debug_line* > by gcc? > > As for general DWARF5 testing, I think best coverage is GDB (say guality > testing with -gdwarf-5), I think GDB 8.0 should have the needed support. > I'll try to install it (am only at 7.12.1 right now) and try to do some > testing. What about Pierre-Marie's work to be able to use python to parse and check dwarf output?
jeff