public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* Question about readelf output from shared library built with lld, gold, and bfd linkers
@ 2022-11-20 16:37 Tom Kacvinsky
  2022-11-21 14:14 ` Nick Clifton
  0 siblings, 1 reply; 8+ messages in thread
From: Tom Kacvinsky @ 2022-11-20 16:37 UTC (permalink / raw)
  To: Binutils

[-- Attachment #1: Type: text/plain, Size: 7945 bytes --]

Isee the following output from readelf for the lld, gold and bfd linkers
(binutils 2.39, lld 14.0.6)
Output below.  Notice how the ordering is different in each case.  The
interesting thing about this is, and why I am looking at various
differences between object code linked by these three linkers, is that I am
trying to track down why startup times are slower due to relocations (based
on the perf tool output).  Would any of these differences make, well, a
difference in startup time?

Thanks,

Tom

Output from readelf for the different linkers.  The particular function is
irrelevant, it happens with other symbols as well.

lld linker:

readelf -Wa libVcAppLib.so | grep ada__strings__search__index
000000000162e508  000055c800000007 R_X86_64_JUMP_SLOT     0000000001571220
ada__strings__search__index + 0
000000000162e510  0000587700000007 R_X86_64_JUMP_SLOT     0000000001570a30
ada__strings__search__index__2 + 0
000000000162e518  0000587d00000007 R_X86_64_JUMP_SLOT     0000000001570c40
ada__strings__search__index__3 + 0
000000000162e520  0000588400000007 R_X86_64_JUMP_SLOT     00000000015715d0
ada__strings__search__index__4 + 0
000000000162e528  0000588a00000007 R_X86_64_JUMP_SLOT     0000000001570d00
ada__strings__search__index__5 + 0
000000000162e530  0000588d00000007 R_X86_64_JUMP_SLOT     0000000001570dd0
ada__strings__search__index__6 + 0
000000000162e540  000003fe00000007 R_X86_64_JUMP_SLOT     0000000001570ea0
ada__strings__search__index_non_blank + 0
000000000162e548  0000278900000007 R_X86_64_JUMP_SLOT     0000000001570f00
ada__strings__search__index_non_blank__2 + 0
  1022: 0000000001570ea0    91 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index_non_blank
 10121: 0000000001570f00   167 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index_non_blank__2
 21960: 0000000001571220   930 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index
 22647: 0000000001570a30   523 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index__2
 22653: 0000000001570c40   187 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index__3
 22660: 00000000015715d0   207 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index__4
 22666: 0000000001570d00   207 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index__5
 22669: 0000000001570dd0   199 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index__6
 36851: 0000000001571220   930 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index
 36853: 0000000001570a30   523 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index__2
 36854: 0000000001570c40   187 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index__3
 36856: 00000000015715d0   207 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index__4
 36858: 0000000001570d00   207 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index__5
 36860: 0000000001570dd0   199 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index__6
 36862: 0000000001570ea0    91 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index_non_blank
 36864: 0000000001570f00   167 FUNC    GLOBAL DEFAULT   14
ada__strings__search__index_non_blank__2

gold linker:

readelf -Wa libVcAppLib.so | grep ada__strings__search__index
0000000001610048  00000f0600000007 R_X86_64_JUMP_SLOT     000000000115a220
ada__strings__search__index + 0
0000000001610050  00003fa300000007 R_X86_64_JUMP_SLOT     0000000001159a30
ada__strings__search__index__2 + 0
0000000001610058  00003fa600000007 R_X86_64_JUMP_SLOT     0000000001159c40
ada__strings__search__index__3 + 0
0000000001610060  00003fa800000007 R_X86_64_JUMP_SLOT     000000000115a5d0
ada__strings__search__index__4 + 0
0000000001610068  00003fa900000007 R_X86_64_JUMP_SLOT     0000000001159d00
ada__strings__search__index__5 + 0
0000000001610070  00003fad00000007 R_X86_64_JUMP_SLOT     0000000001159dd0
ada__strings__search__index__6 + 0
0000000001610078  0000075000000007 R_X86_64_JUMP_SLOT     0000000001159ea0
ada__strings__search__index_non_blank + 0
0000000001610080  000050cb00000007 R_X86_64_JUMP_SLOT     0000000001159f00
ada__strings__search__index_non_blank__2 + 0
  1872: 0000000001159ea0    91 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index_non_blank
  3846: 000000000115a220   930 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index
 16291: 0000000001159a30   523 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__2
 16294: 0000000001159c40   187 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__3
 16296: 000000000115a5d0   207 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__4
 16297: 0000000001159d00   207 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__5
 16301: 0000000001159dd0   199 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__6
 20683: 0000000001159f00   167 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index_non_blank__2
 16810: 0000000001159f00   167 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index_non_blank__2
 16812: 0000000001159ea0    91 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index_non_blank
 16814: 0000000001159dd0   199 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__6
 16816: 0000000001159d00   207 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__5
 16818: 000000000115a5d0   207 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__4
 16820: 0000000001159c40   187 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__3
 16821: 0000000001159a30   523 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__2
 16823: 000000000115a220   930 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index

bfd linker:

readelf -Wa libVcAppLib.so | grep ada__strings__search__index
00000000015db948  00003fa600000007 R_X86_64_JUMP_SLOT     000000000114fa20
ada__strings__search__index__2 + 0
00000000015de700  00003fa800000007 R_X86_64_JUMP_SLOT     000000000114fc30
ada__strings__search__index__3 + 0
00000000015e1908  0000075200000007 R_X86_64_JUMP_SLOT     000000000114fe90
ada__strings__search__index_non_blank + 0
00000000015e55c8  00000f0a00000007 R_X86_64_JUMP_SLOT     0000000001150210
ada__strings__search__index + 0
00000000015e6e40  00003fae00000007 R_X86_64_JUMP_SLOT     000000000114fdc0
ada__strings__search__index__6 + 0
00000000015ec3a0  00003faa00000007 R_X86_64_JUMP_SLOT     00000000011505c0
ada__strings__search__index__4 + 0
00000000015edb08  000050cd00000007 R_X86_64_JUMP_SLOT     000000000114fef0
ada__strings__search__index_non_blank__2 + 0
00000000015ef168  00003fad00000007 R_X86_64_JUMP_SLOT     000000000114fcf0
ada__strings__search__index__5 + 0
  1874: 000000000114fe90    91 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index_non_blank
  3850: 0000000001150210   930 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index
 16294: 000000000114fa20   523 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__2
 16296: 000000000114fc30   187 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__3
 16298: 00000000011505c0   207 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__4
 16301: 000000000114fcf0   207 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__5
 16302: 000000000114fdc0   199 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__6
 20685: 000000000114fef0   167 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index_non_blank__2
 16406: 000000000114fa20   523 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__2
 19426: 000000000114fc30   187 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__3
 22716: 000000000114fe90    91 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index_non_blank
 26768: 0000000001150210   930 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index
 28382: 000000000114fdc0   199 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__6
 34154: 00000000011505c0   207 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__4
 35651: 000000000114fef0   167 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index_non_blank__2
 37103: 000000000114fcf0   207 FUNC    GLOBAL DEFAULT   12
ada__strings__search__index__5

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2022-11-22 11:20 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-20 16:37 Question about readelf output from shared library built with lld, gold, and bfd linkers Tom Kacvinsky
2022-11-21 14:14 ` Nick Clifton
2022-11-21 14:51   ` Tom Kacvinsky
2022-11-21 15:16     ` Nick Clifton
2022-11-21 15:33       ` Tom Kacvinsky
2022-11-21 16:48         ` Nick Clifton
2022-11-21 17:43           ` Tom Kacvinsky
2022-11-22 11:20             ` Nick Clifton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).