logo

oasis-root

Compiled tree of Oasis Linux based on own branch at <https://hacktivis.me/git/oasis/> git clone https://anongit.hacktivis.me/git/oasis-root.git

readelf.1 (30813B)


  1. .\" Automatically generated by Pod::Man 4.14 (Pod::Simple 3.43)
  2. .\"
  3. .\" Standard preamble:
  4. .\" ========================================================================
  5. .de Sp \" Vertical space (when we can't use .PP)
  6. .if t .sp .5v
  7. .if n .sp
  8. ..
  9. .de Vb \" Begin verbatim text
  10. .ft CW
  11. .nf
  12. .ne \\$1
  13. ..
  14. .de Ve \" End verbatim text
  15. .ft R
  16. .fi
  17. ..
  18. .\" Set up some character translations and predefined strings. \*(-- will
  19. .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left
  20. .\" double quote, and \*(R" will give a right double quote. \*(C+ will
  21. .\" give a nicer C++. Capital omega is used to do unbreakable dashes and
  22. .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff,
  23. .\" nothing in troff, for use with C<>.
  24. .tr \(*W-
  25. .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'
  26. .ie n \{\
  27. . ds -- \(*W-
  28. . ds PI pi
  29. . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch
  30. . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch
  31. . ds L" ""
  32. . ds R" ""
  33. . ds C` ""
  34. . ds C' ""
  35. 'br\}
  36. .el\{\
  37. . ds -- \|\(em\|
  38. . ds PI \(*p
  39. . ds L" ``
  40. . ds R" ''
  41. . ds C`
  42. . ds C'
  43. 'br\}
  44. .\"
  45. .\" Escape single quotes in literal strings from groff's Unicode transform.
  46. .ie \n(.g .ds Aq \(aq
  47. .el .ds Aq '
  48. .\"
  49. .\" If the F register is >0, we'll generate index entries on stderr for
  50. .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
  51. .\" entries marked with X<> in POD. Of course, you'll have to process the
  52. .\" output yourself in some meaningful fashion.
  53. .\"
  54. .\" Avoid warning from groff about undefined register 'F'.
  55. .de IX
  56. ..
  57. .nr rF 0
  58. .if \n(.g .if rF .nr rF 1
  59. .if (\n(rF:(\n(.g==0)) \{\
  60. . if \nF \{\
  61. . de IX
  62. . tm Index:\\$1\t\\n%\t"\\$2"
  63. ..
  64. . if !\nF==2 \{\
  65. . nr % 0
  66. . nr F 2
  67. . \}
  68. . \}
  69. .\}
  70. .rr rF
  71. .\"
  72. .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2).
  73. .\" Fear. Run. Save yourself. No user-serviceable parts.
  74. . \" fudge factors for nroff and troff
  75. .if n \{\
  76. . ds #H 0
  77. . ds #V .8m
  78. . ds #F .3m
  79. . ds #[ \f1
  80. . ds #] \fP
  81. .\}
  82. .if t \{\
  83. . ds #H ((1u-(\\\\n(.fu%2u))*.13m)
  84. . ds #V .6m
  85. . ds #F 0
  86. . ds #[ \&
  87. . ds #] \&
  88. .\}
  89. . \" simple accents for nroff and troff
  90. .if n \{\
  91. . ds ' \&
  92. . ds ` \&
  93. . ds ^ \&
  94. . ds , \&
  95. . ds ~ ~
  96. . ds /
  97. .\}
  98. .if t \{\
  99. . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u"
  100. . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'
  101. . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'
  102. . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'
  103. . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'
  104. . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'
  105. .\}
  106. . \" troff and (daisy-wheel) nroff accents
  107. .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'
  108. .ds 8 \h'\*(#H'\(*b\h'-\*(#H'
  109. .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#]
  110. .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'
  111. .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'
  112. .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#]
  113. .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#]
  114. .ds ae a\h'-(\w'a'u*4/10)'e
  115. .ds Ae A\h'-(\w'A'u*4/10)'E
  116. . \" corrections for vroff
  117. .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'
  118. .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'
  119. . \" for low resolution devices (crt and lpr)
  120. .if \n(.H>23 .if \n(.V>19 \
  121. \{\
  122. . ds : e
  123. . ds 8 ss
  124. . ds o a
  125. . ds d- d\h'-1'\(ga
  126. . ds D- D\h'-1'\(hy
  127. . ds th \o'bp'
  128. . ds Th \o'LP'
  129. . ds ae ae
  130. . ds Ae AE
  131. .\}
  132. .rm #[ #] #H #V #F C
  133. .\" ========================================================================
  134. .\"
  135. .IX Title "READELF 1"
  136. .TH READELF 1 "2022-08-05" "binutils-2.39" "GNU Development Tools"
  137. .\" For nroff, turn off justification. Always turn off hyphenation; it makes
  138. .\" way too many mistakes in technical documents.
  139. .if n .ad l
  140. .nh
  141. .SH "NAME"
  142. readelf \- display information about ELF files
  143. .SH "SYNOPSIS"
  144. .IX Header "SYNOPSIS"
  145. readelf [\fB\-a\fR|\fB\-\-all\fR]
  146. [\fB\-h\fR|\fB\-\-file\-header\fR]
  147. [\fB\-l\fR|\fB\-\-program\-headers\fR|\fB\-\-segments\fR]
  148. [\fB\-S\fR|\fB\-\-section\-headers\fR|\fB\-\-sections\fR]
  149. [\fB\-g\fR|\fB\-\-section\-groups\fR]
  150. [\fB\-t\fR|\fB\-\-section\-details\fR]
  151. [\fB\-e\fR|\fB\-\-headers\fR]
  152. [\fB\-s\fR|\fB\-\-syms\fR|\fB\-\-symbols\fR]
  153. [\fB\-\-dyn\-syms\fR|\fB\-\-lto\-syms\fR]
  154. [\fB\-\-sym\-base=[0|8|10|16]\fR]
  155. [\fB\-\-demangle\fR\fI=style\fR|\fB\-\-no\-demangle\fR]
  156. [\fB\-\-quiet\fR]
  157. [\fB\-\-recurse\-limit\fR|\fB\-\-no\-recurse\-limit\fR]
  158. [\fB\-U\fR \fImethod\fR|\fB\-\-unicode=\fR\fImethod\fR]
  159. [\fB\-n\fR|\fB\-\-notes\fR]
  160. [\fB\-r\fR|\fB\-\-relocs\fR]
  161. [\fB\-u\fR|\fB\-\-unwind\fR]
  162. [\fB\-d\fR|\fB\-\-dynamic\fR]
  163. [\fB\-V\fR|\fB\-\-version\-info\fR]
  164. [\fB\-A\fR|\fB\-\-arch\-specific\fR]
  165. [\fB\-D\fR|\fB\-\-use\-dynamic\fR]
  166. [\fB\-L\fR|\fB\-\-lint\fR|\fB\-\-enable\-checks\fR]
  167. [\fB\-x\fR <number or name>|\fB\-\-hex\-dump=\fR<number or name>]
  168. [\fB\-p\fR <number or name>|\fB\-\-string\-dump=\fR<number or name>]
  169. [\fB\-R\fR <number or name>|\fB\-\-relocated\-dump=\fR<number or name>]
  170. [\fB\-z\fR|\fB\-\-decompress\fR]
  171. [\fB\-c\fR|\fB\-\-archive\-index\fR]
  172. [\fB\-w[lLiaprmfFsoORtUuTgAck]\fR|
  173. \fB\-\-debug\-dump\fR[=rawline,=decodedline,=info,=abbrev,=pubnames,=aranges,=macro,=frames,=frames\-interp,=str,=str\-offsets,=loc,=Ranges,=pubtypes,=trace_info,=trace_abbrev,=trace_aranges,=gdb_index,=addr,=cu_index,=links]]
  174. [\fB\-wK\fR|\fB\-\-debug\-dump=follow\-links\fR]
  175. [\fB\-wN\fR|\fB\-\-debug\-dump=no\-follow\-links\fR]
  176. [\fB\-wD\fR|\fB\-\-debug\-dump=use\-debuginfod\fR]
  177. [\fB\-wE\fR|\fB\-\-debug\-dump=do\-not\-use\-debuginfod\fR]
  178. [\fB\-P\fR|\fB\-\-process\-links\fR]
  179. [\fB\-\-dwarf\-depth=\fR\fIn\fR]
  180. [\fB\-\-dwarf\-start=\fR\fIn\fR]
  181. [\fB\-\-ctf=\fR\fIsection\fR]
  182. [\fB\-\-ctf\-parent=\fR\fIsection\fR]
  183. [\fB\-\-ctf\-symbols=\fR\fIsection\fR]
  184. [\fB\-\-ctf\-strings=\fR\fIsection\fR]
  185. [\fB\-I\fR|\fB\-\-histogram\fR]
  186. [\fB\-v\fR|\fB\-\-version\fR]
  187. [\fB\-W\fR|\fB\-\-wide\fR]
  188. [\fB\-T\fR|\fB\-\-silent\-truncation\fR]
  189. [\fB\-H\fR|\fB\-\-help\fR]
  190. \fIelffile\fR...
  191. .SH "DESCRIPTION"
  192. .IX Header "DESCRIPTION"
  193. \&\fBreadelf\fR displays information about one or more \s-1ELF\s0 format object
  194. files. The options control what particular information to display.
  195. .PP
  196. \&\fIelffile\fR... are the object files to be examined. 32\-bit and
  197. 64\-bit \s-1ELF\s0 files are supported, as are archives containing \s-1ELF\s0 files.
  198. .PP
  199. This program performs a similar function to \fBobjdump\fR but it
  200. goes into more detail and it exists independently of the \s-1BFD\s0
  201. library, so if there is a bug in \s-1BFD\s0 then readelf will not be
  202. affected.
  203. .SH "OPTIONS"
  204. .IX Header "OPTIONS"
  205. The long and short forms of options, shown here as alternatives, are
  206. equivalent. At least one option besides \fB\-v\fR or \fB\-H\fR must be
  207. given.
  208. .IP "\fB\-a\fR" 4
  209. .IX Item "-a"
  210. .PD 0
  211. .IP "\fB\-\-all\fR" 4
  212. .IX Item "--all"
  213. .PD
  214. Equivalent to specifying \fB\-\-file\-header\fR,
  215. \&\fB\-\-program\-headers\fR, \fB\-\-sections\fR, \fB\-\-symbols\fR,
  216. \&\fB\-\-relocs\fR, \fB\-\-dynamic\fR, \fB\-\-notes\fR,
  217. \&\fB\-\-version\-info\fR, \fB\-\-arch\-specific\fR, \fB\-\-unwind\fR,
  218. \&\fB\-\-section\-groups\fR and \fB\-\-histogram\fR.
  219. .Sp
  220. Note \- this option does not enable \fB\-\-use\-dynamic\fR itself, so
  221. if that option is not present on the command line then dynamic symbols
  222. and dynamic relocs will not be displayed.
  223. .IP "\fB\-h\fR" 4
  224. .IX Item "-h"
  225. .PD 0
  226. .IP "\fB\-\-file\-header\fR" 4
  227. .IX Item "--file-header"
  228. .PD
  229. Displays the information contained in the \s-1ELF\s0 header at the start of the
  230. file.
  231. .IP "\fB\-l\fR" 4
  232. .IX Item "-l"
  233. .PD 0
  234. .IP "\fB\-\-program\-headers\fR" 4
  235. .IX Item "--program-headers"
  236. .IP "\fB\-\-segments\fR" 4
  237. .IX Item "--segments"
  238. .PD
  239. Displays the information contained in the file's segment headers, if it
  240. has any.
  241. .IP "\fB\-\-quiet\fR" 4
  242. .IX Item "--quiet"
  243. Suppress \*(L"no symbols\*(R" diagnostic.
  244. .IP "\fB\-S\fR" 4
  245. .IX Item "-S"
  246. .PD 0
  247. .IP "\fB\-\-sections\fR" 4
  248. .IX Item "--sections"
  249. .IP "\fB\-\-section\-headers\fR" 4
  250. .IX Item "--section-headers"
  251. .PD
  252. Displays the information contained in the file's section headers, if it
  253. has any.
  254. .IP "\fB\-g\fR" 4
  255. .IX Item "-g"
  256. .PD 0
  257. .IP "\fB\-\-section\-groups\fR" 4
  258. .IX Item "--section-groups"
  259. .PD
  260. Displays the information contained in the file's section groups, if it
  261. has any.
  262. .IP "\fB\-t\fR" 4
  263. .IX Item "-t"
  264. .PD 0
  265. .IP "\fB\-\-section\-details\fR" 4
  266. .IX Item "--section-details"
  267. .PD
  268. Displays the detailed section information. Implies \fB\-S\fR.
  269. .IP "\fB\-s\fR" 4
  270. .IX Item "-s"
  271. .PD 0
  272. .IP "\fB\-\-symbols\fR" 4
  273. .IX Item "--symbols"
  274. .IP "\fB\-\-syms\fR" 4
  275. .IX Item "--syms"
  276. .PD
  277. Displays the entries in symbol table section of the file, if it has one.
  278. If a symbol has version information associated with it then this is
  279. displayed as well. The version string is displayed as a suffix to the
  280. symbol name, preceded by an @ character. For example
  281. \&\fBfoo@VER_1\fR. If the version is the default version to be used
  282. when resolving unversioned references to the symbol then it is
  283. displayed as a suffix preceded by two @ characters. For example
  284. \&\fBfoo@@VER_2\fR.
  285. .IP "\fB\-\-dyn\-syms\fR" 4
  286. .IX Item "--dyn-syms"
  287. Displays the entries in dynamic symbol table section of the file, if it
  288. has one. The output format is the same as the format used by the
  289. \&\fB\-\-syms\fR option.
  290. .IP "\fB\-\-lto\-syms\fR" 4
  291. .IX Item "--lto-syms"
  292. Displays the contents of any \s-1LTO\s0 symbol tables in the file.
  293. .IP "\fB\-\-sym\-base=[0|8|10|16]\fR" 4
  294. .IX Item "--sym-base=[0|8|10|16]"
  295. Forces the size field of the symbol table to use the given base. Any
  296. unrecognized options will be treated as \fB0\fR. \fB\-\-sym\-base=0\fR
  297. represents the default and legacy behaviour. This will output sizes as decimal
  298. for numbers less than 100000. For sizes 100000 and greater hexadecimal notation
  299. will be used with a 0x prefix.
  300. \&\fB\-\-sym\-base=8\fR will give the symbol sizes in octal.
  301. \&\fB\-\-sym\-base=10\fR will always give the symbol sizes in decimal.
  302. \&\fB\-\-sym\-base=16\fR will always give the symbol sizes in hexadecimal with a
  303. 0x prefix.
  304. .IP "\fB\-C\fR" 4
  305. .IX Item "-C"
  306. .PD 0
  307. .IP "\fB\-\-demangle[=\fR\fIstyle\fR\fB]\fR" 4
  308. .IX Item "--demangle[=style]"
  309. .PD
  310. Decode (\fIdemangle\fR) low-level symbol names into user-level names.
  311. This makes \*(C+ function names readable. Different compilers have
  312. different mangling styles. The optional demangling style argument can
  313. be used to choose an appropriate demangling style for your
  314. compiler.
  315. .IP "\fB\-\-no\-demangle\fR" 4
  316. .IX Item "--no-demangle"
  317. Do not demangle low-level symbol names. This is the default.
  318. .IP "\fB\-\-recurse\-limit\fR" 4
  319. .IX Item "--recurse-limit"
  320. .PD 0
  321. .IP "\fB\-\-no\-recurse\-limit\fR" 4
  322. .IX Item "--no-recurse-limit"
  323. .IP "\fB\-\-recursion\-limit\fR" 4
  324. .IX Item "--recursion-limit"
  325. .IP "\fB\-\-no\-recursion\-limit\fR" 4
  326. .IX Item "--no-recursion-limit"
  327. .PD
  328. Enables or disables a limit on the amount of recursion performed
  329. whilst demangling strings. Since the name mangling formats allow for
  330. an infinite level of recursion it is possible to create strings whose
  331. decoding will exhaust the amount of stack space available on the host
  332. machine, triggering a memory fault. The limit tries to prevent this
  333. from happening by restricting recursion to 2048 levels of nesting.
  334. .Sp
  335. The default is for this limit to be enabled, but disabling it may be
  336. necessary in order to demangle truly complicated names. Note however
  337. that if the recursion limit is disabled then stack exhaustion is
  338. possible and any bug reports about such an event will be rejected.
  339. .IP "\fB\-U\fR \fI[d|i|l|e|x|h]\fR" 4
  340. .IX Item "-U [d|i|l|e|x|h]"
  341. .PD 0
  342. .IP "\fB\-\-unicode=[default|invalid|locale|escape|hex|highlight]\fR" 4
  343. .IX Item "--unicode=[default|invalid|locale|escape|hex|highlight]"
  344. .PD
  345. Controls the display of non-ASCII characters in identifier names.
  346. The default (\fB\-\-unicode=locale\fR or \fB\-\-unicode=default\fR) is
  347. to treat them as multibyte characters and display them in the current
  348. locale. All other versions of this option treat the bytes as \s-1UTF\-8\s0
  349. encoded values and attempt to interpret them. If they cannot be
  350. interpreted or if the \fB\-\-unicode=invalid\fR option is used then
  351. they are displayed as a sequence of hex bytes, encloses in curly
  352. parethesis characters.
  353. .Sp
  354. Using the \fB\-\-unicode=escape\fR option will display the characters
  355. as as unicode escape sequences (\fI\euxxxx\fR). Using the
  356. \&\fB\-\-unicode=hex\fR will display the characters as hex byte
  357. sequences enclosed between angle brackets.
  358. .Sp
  359. Using the \fB\-\-unicode=highlight\fR will display the characters as
  360. unicode escape sequences but it will also highlighted them in red,
  361. assuming that colouring is supported by the output device. The
  362. colouring is intended to draw attention to the presence of unicode
  363. sequences when they might not be expected.
  364. .IP "\fB\-e\fR" 4
  365. .IX Item "-e"
  366. .PD 0
  367. .IP "\fB\-\-headers\fR" 4
  368. .IX Item "--headers"
  369. .PD
  370. Display all the headers in the file. Equivalent to \fB\-h \-l \-S\fR.
  371. .IP "\fB\-n\fR" 4
  372. .IX Item "-n"
  373. .PD 0
  374. .IP "\fB\-\-notes\fR" 4
  375. .IX Item "--notes"
  376. .PD
  377. Displays the contents of the \s-1NOTE\s0 segments and/or sections, if any.
  378. .IP "\fB\-r\fR" 4
  379. .IX Item "-r"
  380. .PD 0
  381. .IP "\fB\-\-relocs\fR" 4
  382. .IX Item "--relocs"
  383. .PD
  384. Displays the contents of the file's relocation section, if it has one.
  385. .IP "\fB\-u\fR" 4
  386. .IX Item "-u"
  387. .PD 0
  388. .IP "\fB\-\-unwind\fR" 4
  389. .IX Item "--unwind"
  390. .PD
  391. Displays the contents of the file's unwind section, if it has one. Only
  392. the unwind sections for \s-1IA64 ELF\s0 files, as well as \s-1ARM\s0 unwind tables
  393. (\f(CW\*(C`.ARM.exidx\*(C'\fR / \f(CW\*(C`.ARM.extab\*(C'\fR) are currently supported. If
  394. support is not yet implemented for your architecture you could try
  395. dumping the contents of the \fI.eh_frames\fR section using the
  396. \&\fB\-\-debug\-dump=frames\fR or \fB\-\-debug\-dump=frames\-interp\fR
  397. options.
  398. .IP "\fB\-d\fR" 4
  399. .IX Item "-d"
  400. .PD 0
  401. .IP "\fB\-\-dynamic\fR" 4
  402. .IX Item "--dynamic"
  403. .PD
  404. Displays the contents of the file's dynamic section, if it has one.
  405. .IP "\fB\-V\fR" 4
  406. .IX Item "-V"
  407. .PD 0
  408. .IP "\fB\-\-version\-info\fR" 4
  409. .IX Item "--version-info"
  410. .PD
  411. Displays the contents of the version sections in the file, it they
  412. exist.
  413. .IP "\fB\-A\fR" 4
  414. .IX Item "-A"
  415. .PD 0
  416. .IP "\fB\-\-arch\-specific\fR" 4
  417. .IX Item "--arch-specific"
  418. .PD
  419. Displays architecture-specific information in the file, if there
  420. is any.
  421. .IP "\fB\-D\fR" 4
  422. .IX Item "-D"
  423. .PD 0
  424. .IP "\fB\-\-use\-dynamic\fR" 4
  425. .IX Item "--use-dynamic"
  426. .PD
  427. When displaying symbols, this option makes \fBreadelf\fR use the
  428. symbol hash tables in the file's dynamic section, rather than the
  429. symbol table sections.
  430. .Sp
  431. When displaying relocations, this option makes \fBreadelf\fR
  432. display the dynamic relocations rather than the static relocations.
  433. .IP "\fB\-L\fR" 4
  434. .IX Item "-L"
  435. .PD 0
  436. .IP "\fB\-\-lint\fR" 4
  437. .IX Item "--lint"
  438. .IP "\fB\-\-enable\-checks\fR" 4
  439. .IX Item "--enable-checks"
  440. .PD
  441. Displays warning messages about possible problems with the file(s)
  442. being examined. If used on its own then all of the contents of the
  443. file(s) will be examined. If used with one of the dumping options
  444. then the warning messages will only be produced for the things being
  445. displayed.
  446. .IP "\fB\-x <number or name>\fR" 4
  447. .IX Item "-x <number or name>"
  448. .PD 0
  449. .IP "\fB\-\-hex\-dump=<number or name>\fR" 4
  450. .IX Item "--hex-dump=<number or name>"
  451. .PD
  452. Displays the contents of the indicated section as a hexadecimal bytes.
  453. A number identifies a particular section by index in the section table;
  454. any other string identifies all sections with that name in the object file.
  455. .IP "\fB\-R <number or name>\fR" 4
  456. .IX Item "-R <number or name>"
  457. .PD 0
  458. .IP "\fB\-\-relocated\-dump=<number or name>\fR" 4
  459. .IX Item "--relocated-dump=<number or name>"
  460. .PD
  461. Displays the contents of the indicated section as a hexadecimal
  462. bytes. A number identifies a particular section by index in the
  463. section table; any other string identifies all sections with that name
  464. in the object file. The contents of the section will be relocated
  465. before they are displayed.
  466. .IP "\fB\-p <number or name>\fR" 4
  467. .IX Item "-p <number or name>"
  468. .PD 0
  469. .IP "\fB\-\-string\-dump=<number or name>\fR" 4
  470. .IX Item "--string-dump=<number or name>"
  471. .PD
  472. Displays the contents of the indicated section as printable strings.
  473. A number identifies a particular section by index in the section table;
  474. any other string identifies all sections with that name in the object file.
  475. .IP "\fB\-z\fR" 4
  476. .IX Item "-z"
  477. .PD 0
  478. .IP "\fB\-\-decompress\fR" 4
  479. .IX Item "--decompress"
  480. .PD
  481. Requests that the section(s) being dumped by \fBx\fR, \fBR\fR or
  482. \&\fBp\fR options are decompressed before being displayed. If the
  483. section(s) are not compressed then they are displayed as is.
  484. .IP "\fB\-c\fR" 4
  485. .IX Item "-c"
  486. .PD 0
  487. .IP "\fB\-\-archive\-index\fR" 4
  488. .IX Item "--archive-index"
  489. .PD
  490. Displays the file symbol index information contained in the header part
  491. of binary archives. Performs the same function as the \fBt\fR
  492. command to \fBar\fR, but without using the \s-1BFD\s0 library.
  493. .IP "\fB\-w[lLiaprmfFsOoRtUuTgAckK]\fR" 4
  494. .IX Item "-w[lLiaprmfFsOoRtUuTgAckK]"
  495. .PD 0
  496. .IP "\fB\-\-debug\-dump[=rawline,=decodedline,=info,=abbrev,=pubnames,=aranges,=macro,=frames,=frames\-interp,=str,=str\-offsets,=loc,=Ranges,=pubtypes,=trace_info,=trace_abbrev,=trace_aranges,=gdb_index,=addr,=cu_index,=links,=follow\-links]\fR" 4
  497. .IX Item "--debug-dump[=rawline,=decodedline,=info,=abbrev,=pubnames,=aranges,=macro,=frames,=frames-interp,=str,=str-offsets,=loc,=Ranges,=pubtypes,=trace_info,=trace_abbrev,=trace_aranges,=gdb_index,=addr,=cu_index,=links,=follow-links]"
  498. .PD
  499. Displays the contents of the \s-1DWARF\s0 debug sections in the file, if any
  500. are present. Compressed debug sections are automatically decompressed
  501. (temporarily) before they are displayed. If one or more of the
  502. optional letters or words follows the switch then only those type(s)
  503. of data will be dumped. The letters and words refer to the following
  504. information:
  505. .RS 4
  506. .ie n .IP """a""" 4
  507. .el .IP "\f(CWa\fR" 4
  508. .IX Item "a"
  509. .PD 0
  510. .ie n .IP """=abbrev""" 4
  511. .el .IP "\f(CW=abbrev\fR" 4
  512. .IX Item "=abbrev"
  513. .PD
  514. Displays the contents of the \fB.debug_abbrev\fR section.
  515. .ie n .IP """A""" 4
  516. .el .IP "\f(CWA\fR" 4
  517. .IX Item "A"
  518. .PD 0
  519. .ie n .IP """=addr""" 4
  520. .el .IP "\f(CW=addr\fR" 4
  521. .IX Item "=addr"
  522. .PD
  523. Displays the contents of the \fB.debug_addr\fR section.
  524. .ie n .IP """c""" 4
  525. .el .IP "\f(CWc\fR" 4
  526. .IX Item "c"
  527. .PD 0
  528. .ie n .IP """=cu_index""" 4
  529. .el .IP "\f(CW=cu_index\fR" 4
  530. .IX Item "=cu_index"
  531. .PD
  532. Displays the contents of the \fB.debug_cu_index\fR and/or
  533. \&\fB.debug_tu_index\fR sections.
  534. .ie n .IP """f""" 4
  535. .el .IP "\f(CWf\fR" 4
  536. .IX Item "f"
  537. .PD 0
  538. .ie n .IP """=frames""" 4
  539. .el .IP "\f(CW=frames\fR" 4
  540. .IX Item "=frames"
  541. .PD
  542. Display the raw contents of a \fB.debug_frame\fR section.
  543. .ie n .IP """F""" 4
  544. .el .IP "\f(CWF\fR" 4
  545. .IX Item "F"
  546. .PD 0
  547. .ie n .IP """=frames\-interp""" 4
  548. .el .IP "\f(CW=frames\-interp\fR" 4
  549. .IX Item "=frames-interp"
  550. .PD
  551. Display the interpreted contents of a \fB.debug_frame\fR section.
  552. .ie n .IP """g""" 4
  553. .el .IP "\f(CWg\fR" 4
  554. .IX Item "g"
  555. .PD 0
  556. .ie n .IP """=gdb_index""" 4
  557. .el .IP "\f(CW=gdb_index\fR" 4
  558. .IX Item "=gdb_index"
  559. .PD
  560. Displays the contents of the \fB.gdb_index\fR and/or
  561. \&\fB.debug_names\fR sections.
  562. .ie n .IP """i""" 4
  563. .el .IP "\f(CWi\fR" 4
  564. .IX Item "i"
  565. .PD 0
  566. .ie n .IP """=info""" 4
  567. .el .IP "\f(CW=info\fR" 4
  568. .IX Item "=info"
  569. .PD
  570. Displays the contents of the \fB.debug_info\fR section. Note: the
  571. output from this option can also be restricted by the use of the
  572. \&\fB\-\-dwarf\-depth\fR and \fB\-\-dwarf\-start\fR options.
  573. .ie n .IP """k""" 4
  574. .el .IP "\f(CWk\fR" 4
  575. .IX Item "k"
  576. .PD 0
  577. .ie n .IP """=links""" 4
  578. .el .IP "\f(CW=links\fR" 4
  579. .IX Item "=links"
  580. .PD
  581. Displays the contents of the \fB.gnu_debuglink\fR,
  582. \&\fB.gnu_debugaltlink\fR and \fB.debug_sup\fR sections, if any of
  583. them are present. Also displays any links to separate dwarf object
  584. files (dwo), if they are specified by the DW_AT_GNU_dwo_name or
  585. DW_AT_dwo_name attributes in the \fB.debug_info\fR section.
  586. .ie n .IP """K""" 4
  587. .el .IP "\f(CWK\fR" 4
  588. .IX Item "K"
  589. .PD 0
  590. .ie n .IP """=follow\-links""" 4
  591. .el .IP "\f(CW=follow\-links\fR" 4
  592. .IX Item "=follow-links"
  593. .PD
  594. Display the contents of any selected debug sections that are found in
  595. linked, separate debug info file(s). This can result in multiple
  596. versions of the same debug section being displayed if it exists in
  597. more than one file.
  598. .Sp
  599. In addition, when displaying \s-1DWARF\s0 attributes, if a form is found that
  600. references the separate debug info file, then the referenced contents
  601. will also be displayed.
  602. .Sp
  603. Note \- in some distributions this option is enabled by default. It
  604. can be disabled via the \fBN\fR debug option. The default can be
  605. chosen when configuring the binutils via the
  606. \&\fB\-\-enable\-follow\-debug\-links=yes\fR or
  607. \&\fB\-\-enable\-follow\-debug\-links=no\fR options. If these are not
  608. used then the default is to enable the following of debug links.
  609. .Sp
  610. Note \- if support for the debuginfod protocol was enabled when the
  611. binutils were built then this option will also include an attempt to
  612. contact any debuginfod servers mentioned in the \fI\s-1DEBUGINFOD_URLS\s0\fR
  613. environment variable. This could take some time to resolve. This
  614. behaviour can be disabled via the \fB=do\-not\-use\-debuginfod\fR debug
  615. option.
  616. .ie n .IP """N""" 4
  617. .el .IP "\f(CWN\fR" 4
  618. .IX Item "N"
  619. .PD 0
  620. .ie n .IP """=no\-follow\-links""" 4
  621. .el .IP "\f(CW=no\-follow\-links\fR" 4
  622. .IX Item "=no-follow-links"
  623. .PD
  624. Disables the following of links to separate debug info files.
  625. .ie n .IP """D""" 4
  626. .el .IP "\f(CWD\fR" 4
  627. .IX Item "D"
  628. .PD 0
  629. .ie n .IP """=use\-debuginfod""" 4
  630. .el .IP "\f(CW=use\-debuginfod\fR" 4
  631. .IX Item "=use-debuginfod"
  632. .PD
  633. Enables contacting debuginfod servers if there is a need to follow
  634. debug links. This is the default behaviour.
  635. .ie n .IP """E""" 4
  636. .el .IP "\f(CWE\fR" 4
  637. .IX Item "E"
  638. .PD 0
  639. .ie n .IP """=do\-not\-use\-debuginfod""" 4
  640. .el .IP "\f(CW=do\-not\-use\-debuginfod\fR" 4
  641. .IX Item "=do-not-use-debuginfod"
  642. .PD
  643. Disables contacting debuginfod servers when there is a need to follow
  644. debug links.
  645. .ie n .IP """l""" 4
  646. .el .IP "\f(CWl\fR" 4
  647. .IX Item "l"
  648. .PD 0
  649. .ie n .IP """=rawline""" 4
  650. .el .IP "\f(CW=rawline\fR" 4
  651. .IX Item "=rawline"
  652. .PD
  653. Displays the contents of the \fB.debug_line\fR section in a raw
  654. format.
  655. .ie n .IP """L""" 4
  656. .el .IP "\f(CWL\fR" 4
  657. .IX Item "L"
  658. .PD 0
  659. .ie n .IP """=decodedline""" 4
  660. .el .IP "\f(CW=decodedline\fR" 4
  661. .IX Item "=decodedline"
  662. .PD
  663. Displays the interpreted contents of the \fB.debug_line\fR section.
  664. .ie n .IP """m""" 4
  665. .el .IP "\f(CWm\fR" 4
  666. .IX Item "m"
  667. .PD 0
  668. .ie n .IP """=macro""" 4
  669. .el .IP "\f(CW=macro\fR" 4
  670. .IX Item "=macro"
  671. .PD
  672. Displays the contents of the \fB.debug_macro\fR and/or
  673. \&\fB.debug_macinfo\fR sections.
  674. .ie n .IP """o""" 4
  675. .el .IP "\f(CWo\fR" 4
  676. .IX Item "o"
  677. .PD 0
  678. .ie n .IP """=loc""" 4
  679. .el .IP "\f(CW=loc\fR" 4
  680. .IX Item "=loc"
  681. .PD
  682. Displays the contents of the \fB.debug_loc\fR and/or
  683. \&\fB.debug_loclists\fR sections.
  684. .ie n .IP """O""" 4
  685. .el .IP "\f(CWO\fR" 4
  686. .IX Item "O"
  687. .PD 0
  688. .ie n .IP """=str\-offsets""" 4
  689. .el .IP "\f(CW=str\-offsets\fR" 4
  690. .IX Item "=str-offsets"
  691. .PD
  692. Displays the contents of the \fB.debug_str_offsets\fR section.
  693. .ie n .IP """p""" 4
  694. .el .IP "\f(CWp\fR" 4
  695. .IX Item "p"
  696. .PD 0
  697. .ie n .IP """=pubnames""" 4
  698. .el .IP "\f(CW=pubnames\fR" 4
  699. .IX Item "=pubnames"
  700. .PD
  701. Displays the contents of the \fB.debug_pubnames\fR and/or
  702. \&\fB.debug_gnu_pubnames\fR sections.
  703. .ie n .IP """r""" 4
  704. .el .IP "\f(CWr\fR" 4
  705. .IX Item "r"
  706. .PD 0
  707. .ie n .IP """=aranges""" 4
  708. .el .IP "\f(CW=aranges\fR" 4
  709. .IX Item "=aranges"
  710. .PD
  711. Displays the contents of the \fB.debug_aranges\fR section.
  712. .ie n .IP """R""" 4
  713. .el .IP "\f(CWR\fR" 4
  714. .IX Item "R"
  715. .PD 0
  716. .ie n .IP """=Ranges""" 4
  717. .el .IP "\f(CW=Ranges\fR" 4
  718. .IX Item "=Ranges"
  719. .PD
  720. Displays the contents of the \fB.debug_ranges\fR and/or
  721. \&\fB.debug_rnglists\fR sections.
  722. .ie n .IP """s""" 4
  723. .el .IP "\f(CWs\fR" 4
  724. .IX Item "s"
  725. .PD 0
  726. .ie n .IP """=str""" 4
  727. .el .IP "\f(CW=str\fR" 4
  728. .IX Item "=str"
  729. .PD
  730. Displays the contents of the \fB.debug_str\fR, \fB.debug_line_str\fR
  731. and/or \fB.debug_str_offsets\fR sections.
  732. .ie n .IP """t""" 4
  733. .el .IP "\f(CWt\fR" 4
  734. .IX Item "t"
  735. .PD 0
  736. .ie n .IP """=pubtype""" 4
  737. .el .IP "\f(CW=pubtype\fR" 4
  738. .IX Item "=pubtype"
  739. .PD
  740. Displays the contents of the \fB.debug_pubtypes\fR and/or
  741. \&\fB.debug_gnu_pubtypes\fR sections.
  742. .ie n .IP """T""" 4
  743. .el .IP "\f(CWT\fR" 4
  744. .IX Item "T"
  745. .PD 0
  746. .ie n .IP """=trace_aranges""" 4
  747. .el .IP "\f(CW=trace_aranges\fR" 4
  748. .IX Item "=trace_aranges"
  749. .PD
  750. Displays the contents of the \fB.trace_aranges\fR section.
  751. .ie n .IP """u""" 4
  752. .el .IP "\f(CWu\fR" 4
  753. .IX Item "u"
  754. .PD 0
  755. .ie n .IP """=trace_abbrev""" 4
  756. .el .IP "\f(CW=trace_abbrev\fR" 4
  757. .IX Item "=trace_abbrev"
  758. .PD
  759. Displays the contents of the \fB.trace_abbrev\fR section.
  760. .ie n .IP """U""" 4
  761. .el .IP "\f(CWU\fR" 4
  762. .IX Item "U"
  763. .PD 0
  764. .ie n .IP """=trace_info""" 4
  765. .el .IP "\f(CW=trace_info\fR" 4
  766. .IX Item "=trace_info"
  767. .PD
  768. Displays the contents of the \fB.trace_info\fR section.
  769. .RE
  770. .RS 4
  771. .Sp
  772. Note: displaying the contents of \fB.debug_static_funcs\fR,
  773. \&\fB.debug_static_vars\fR and \fBdebug_weaknames\fR sections is not
  774. currently supported.
  775. .RE
  776. .IP "\fB\-\-dwarf\-depth=\fR\fIn\fR" 4
  777. .IX Item "--dwarf-depth=n"
  778. Limit the dump of the \f(CW\*(C`.debug_info\*(C'\fR section to \fIn\fR children.
  779. This is only useful with \fB\-\-debug\-dump=info\fR. The default is
  780. to print all DIEs; the special value 0 for \fIn\fR will also have this
  781. effect.
  782. .Sp
  783. With a non-zero value for \fIn\fR, DIEs at or deeper than \fIn\fR
  784. levels will not be printed. The range for \fIn\fR is zero-based.
  785. .IP "\fB\-\-dwarf\-start=\fR\fIn\fR" 4
  786. .IX Item "--dwarf-start=n"
  787. Print only DIEs beginning with the \s-1DIE\s0 numbered \fIn\fR. This is only
  788. useful with \fB\-\-debug\-dump=info\fR.
  789. .Sp
  790. If specified, this option will suppress printing of any header
  791. information and all DIEs before the \s-1DIE\s0 numbered \fIn\fR. Only
  792. siblings and children of the specified \s-1DIE\s0 will be printed.
  793. .Sp
  794. This can be used in conjunction with \fB\-\-dwarf\-depth\fR.
  795. .IP "\fB\-P\fR" 4
  796. .IX Item "-P"
  797. .PD 0
  798. .IP "\fB\-\-process\-links\fR" 4
  799. .IX Item "--process-links"
  800. .PD
  801. Display the contents of non-debug sections found in separate debuginfo
  802. files that are linked to the main file. This option automatically
  803. implies the \fB\-wK\fR option, and only sections requested by other
  804. command line options will be displayed.
  805. .IP "\fB\-\-ctf[=\fR\fIsection\fR\fB]\fR" 4
  806. .IX Item "--ctf[=section]"
  807. Display the contents of the specified \s-1CTF\s0 section. \s-1CTF\s0 sections themselves
  808. contain many subsections, all of which are displayed in order.
  809. .Sp
  810. By default, display the name of the section named \fI.ctf\fR, which is the
  811. name emitted by \fBld\fR.
  812. .IP "\fB\-\-ctf\-parent=\fR\fImember\fR" 4
  813. .IX Item "--ctf-parent=member"
  814. If the \s-1CTF\s0 section contains ambiguously-defined types, it will consist
  815. of an archive of many \s-1CTF\s0 dictionaries, all inheriting from one
  816. dictionary containing unambiguous types. This member is by default
  817. named \fI.ctf\fR, like the section containing it, but it is possible to
  818. change this name using the \f(CW\*(C`ctf_link_set_memb_name_changer\*(C'\fR
  819. function at link time. When looking at \s-1CTF\s0 archives that have been
  820. created by a linker that uses the name changer to rename the parent
  821. archive member, \fB\-\-ctf\-parent\fR can be used to specify the name
  822. used for the parent.
  823. .IP "\fB\-\-ctf\-symbols=\fR\fIsection\fR" 4
  824. .IX Item "--ctf-symbols=section"
  825. .PD 0
  826. .IP "\fB\-\-ctf\-strings=\fR\fIsection\fR" 4
  827. .IX Item "--ctf-strings=section"
  828. .PD
  829. Specify the name of another section from which the \s-1CTF\s0 file can inherit
  830. strings and symbols. By default, the \f(CW\*(C`.symtab\*(C'\fR and its linked
  831. string table are used.
  832. .Sp
  833. If either of \fB\-\-ctf\-symbols\fR or \fB\-\-ctf\-strings\fR is specified, the
  834. other must be specified as well.
  835. .IP "\fB\-I\fR" 4
  836. .IX Item "-I"
  837. .PD 0
  838. .IP "\fB\-\-histogram\fR" 4
  839. .IX Item "--histogram"
  840. .PD
  841. Display a histogram of bucket list lengths when displaying the contents
  842. of the symbol tables.
  843. .IP "\fB\-v\fR" 4
  844. .IX Item "-v"
  845. .PD 0
  846. .IP "\fB\-\-version\fR" 4
  847. .IX Item "--version"
  848. .PD
  849. Display the version number of readelf.
  850. .IP "\fB\-W\fR" 4
  851. .IX Item "-W"
  852. .PD 0
  853. .IP "\fB\-\-wide\fR" 4
  854. .IX Item "--wide"
  855. .PD
  856. Don't break output lines to fit into 80 columns. By default
  857. \&\fBreadelf\fR breaks section header and segment listing lines for
  858. 64\-bit \s-1ELF\s0 files, so that they fit into 80 columns. This option causes
  859. \&\fBreadelf\fR to print each section header resp. each segment one a
  860. single line, which is far more readable on terminals wider than 80 columns.
  861. .IP "\fB\-T\fR" 4
  862. .IX Item "-T"
  863. .PD 0
  864. .IP "\fB\-\-silent\-truncation\fR" 4
  865. .IX Item "--silent-truncation"
  866. .PD
  867. Normally when readelf is displaying a symbol name, and it has to
  868. truncate the name to fit into an 80 column display, it will add a
  869. suffix of \f(CW\*(C`[...]\*(C'\fR to the name. This command line option
  870. disables this behaviour, allowing 5 more characters of the name to be
  871. displayed and restoring the old behaviour of readelf (prior to release
  872. 2.35).
  873. .IP "\fB\-H\fR" 4
  874. .IX Item "-H"
  875. .PD 0
  876. .IP "\fB\-\-help\fR" 4
  877. .IX Item "--help"
  878. .PD
  879. Display the command-line options understood by \fBreadelf\fR.
  880. .IP "\fB@\fR\fIfile\fR" 4
  881. .IX Item "@file"
  882. Read command-line options from \fIfile\fR. The options read are
  883. inserted in place of the original @\fIfile\fR option. If \fIfile\fR
  884. does not exist, or cannot be read, then the option will be treated
  885. literally, and not removed.
  886. .Sp
  887. Options in \fIfile\fR are separated by whitespace. A whitespace
  888. character may be included in an option by surrounding the entire
  889. option in either single or double quotes. Any character (including a
  890. backslash) may be included by prefixing the character to be included
  891. with a backslash. The \fIfile\fR may itself contain additional
  892. @\fIfile\fR options; any such options will be processed recursively.
  893. .SH "SEE ALSO"
  894. .IX Header "SEE ALSO"
  895. \&\fBobjdump\fR\|(1), and the Info entries for \fIbinutils\fR.
  896. .SH "COPYRIGHT"
  897. .IX Header "COPYRIGHT"
  898. Copyright (c) 1991\-2022 Free Software Foundation, Inc.
  899. .PP
  900. Permission is granted to copy, distribute and/or modify this document
  901. under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.3
  902. or any later version published by the Free Software Foundation;
  903. with no Invariant Sections, with no Front-Cover Texts, and with no
  904. Back-Cover Texts. A copy of the license is included in the
  905. section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".