[llvm-dev] [LLD] Slow callstacks in gdb
Martin Richtarsky via llvm-dev
llvm-dev at lists.llvm.org
Tue Dec 5 01:01:21 PST 2017
>> When building with gcc 6.2.1 and linking with lld trunk, I get a link
>> error:
>>
>> bin-lld/ld: error: lib/libse.a(file1.cpp.o): unaligned data
>
> That means that file1.cpp.o has an invalid sh_offset. Can you post a
> readelf -SW of it? How is it being created?
>
> The error is from ELF.h: ELFFile<ELFT>::getSectionContentsAsArray.
Output looks as follows [1] Seems sh_offset is missing?
The object file was created with ICC (not sure which version)
Best regards,
Martin
[1]
There are 25 section headers, starting at offset 0xd5e50:
Section Headers:
[Nr] Name Type Address Off Size ES
Flg Lk Inf Al
[ 0] NULL 0000000000000000 000000 000000 00
0 0 0
[ 1] .symtab SYMTAB 0000000000000000 000040 000228 18
16 17 4
[ 2] .data PROGBITS 0000000000000000 000268 000000 00
WA 0 0 4
[ 3] .bss NOBITS 0000000000000000 000268 000000 00
WA 0 0 4
[ 4] .text PROGBITS 0000000000000000 000268 010330 00
AX 0 0 16
[ 5] .rodata PROGBITS 0000000000000000 010598 001460 00
A 0 0 32
[ 6] .debug_opt_report PROGBITS 0000000000000000 0119f8 002d52 00
0 0 1
[ 7] .note.GNU-stack NOTE 0000000000000000 01474a 000000 00
0 0 1
[ 8] .debug_info PROGBITS 0000000000000000 01474a 020d66 00
0 0 1
[ 9] .debug_line PROGBITS 0000000000000000 0354b0 00968b 00
0 0 1
[10] .debug_abbrev PROGBITS 0000000000000000 03eb3b 0003ea 00
0 0 1
[11] .debug_frame PROGBITS 0000000000000000 03ef25 001220 00
0 0 1
[12] .debug_str PROGBITS 0000000000000000 040145 018b94 01
MS 0 0 1
[13] .eh_frame PROGBITS 0000000000000000 058cd9 001220 00
A 0 0 8
[14] .debug_ranges PROGBITS 0000000000000000 059ef9 016000 00
0 0 1
[15] .gnu.linkonce.d.DW.ref.__gxx_personality_v0 PROGBITS
0000000000000000 06fef9 000008 00 A 0 0 1
[16] .strtab STRTAB 0000000000000000 06ff01 001522 00
0 0 1
[17] .rela.text RELA 0000000000000000 071423 001728 18
1 4 8
[18] .rela.debug_opt_report RELA 0000000000000000 072b4b
001fb0 18 1 6 8
[19] .rela.debug_info RELA 0000000000000000 074afb 028680 18
1 8 8
[20] .rela.debug_line RELA 0000000000000000 09d17b 000048 18
1 9 8
[21] .rela.debug_frame RELA 0000000000000000 09d1c3 000090 18
1 11 8
[22] .rela.eh_frame RELA 0000000000000000 09d253 000060 18
1 13 8
[23] .rela.debug_ranges RELA 0000000000000000 09d2b3 038b80
18 1 14 8
[24] .rela.gnu.linkonce.d.DW.ref.__gxx_personality_v0 RELA
0000000000000000 0d5e33 000018 18 1 15 8
Key to Flags:
W (write), A (alloc), X (execute), M (merge), S (strings), l (large)
I (info), L (link order), G (group), T (TLS), E (exclude), x (unknown)
O (extra OS processing required) o (OS specific), p (processor specific)
--
http://www.productive-cpp.com/
More information about the llvm-dev
mailing list