https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86469

--- Comment #10 from Jonny Grant <jg at jguk dot org> ---
[copy from other ticket]

(In reply to Richard Biener from comment #3)
> (In reply to Jonny Grant from comment #0)
> > It's pretty hard to work out which file this o file comes from. Could it
> > include the first file name in the tmp path to make it clearer where it came
> > from?  
> > 
> > Currently:
> > /tmp/ccDxn2Yd.ltrans0.ltrans.o
> > 
> > Expected:
> > /tmp/main.cpp.ccDxn2Yd.ltrans0.ltrans.o
> > 
> > Example below of what I see
> > 
> > jonny@asus:~/domains$ make
> > g++-8 -std=c++11 -g -ggdb -pthread -O0 -Werror -Wextra -Wshadow
> > -Wformat-nonliteral -Wall -Wnonnull -Wpedantic -fstack-protector-strong 
> > -Wdiv-by-zero -Wsign-conversion -Wnull-dereference -flto
> > -Wno-nonnull-compare -o proc main.cpp test_whois.cpp <snip file list>
> > /usr/bin/x86_64-linux-gnu-ld: Dwarf Error: Offset (1678049557) greater than
> > or equal to .debug_str size (5846).
> 
> ^^^
> 
> oh, and as for this DWARF section sizes are limited to 2GB as offsets are
> 32bits only.  The above offset is 0x64050115 which _may_ indicate an
> overflow (and .debug_str is unlikely to be just 5846 bytes in size).
> 
> If you do not use LTO how large are your .debug_* sections in the final
> executable?




Hi Richard

WITH LTO   -flto
Idx Name          Size      VMA               LMA               File off  Algn
 31 .debug_str    000c1a35  0000000000000000  0000000000000000  0021043a  2**0
                  CONTENTS, READONLY, DEBUGGING

793,141 bytes

WITHOUT LTO:     
Idx Name          Size      VMA               LMA               File off  Algn
31 .debug_str    000c180c  0000000000000000  0000000000000000  0023394f  2**0
                  CONTENTS, READONLY, DEBUGGING
792,588 bytes

Reply via email to