You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

arm-none-eabi-c++filt.1 12KB

3 jaren geleden
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376
  1. .\" Automatically generated by Pod::Man 2.27 (Pod::Simple 3.28)
  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 turned on, 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 "C++FILT 1"
  136. .TH C++FILT 1 "2020-11-24" "binutils-2.35.1" "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. c++filt \- demangle C++ and Java symbols
  143. .SH "SYNOPSIS"
  144. .IX Header "SYNOPSIS"
  145. c++filt [\fB\-_\fR|\fB\-\-strip\-underscore\fR]
  146. [\fB\-n\fR|\fB\-\-no\-strip\-underscore\fR]
  147. [\fB\-p\fR|\fB\-\-no\-params\fR]
  148. [\fB\-t\fR|\fB\-\-types\fR]
  149. [\fB\-i\fR|\fB\-\-no\-verbose\fR]
  150. [\fB\-r\fR|\fB\-\-no\-recurse\-limit\fR]
  151. [\fB\-R\fR|\fB\-\-recurse\-limit\fR]
  152. [\fB\-s\fR \fIformat\fR|\fB\-\-format=\fR\fIformat\fR]
  153. [\fB\-\-help\fR] [\fB\-\-version\fR] [\fIsymbol\fR...]
  154. .SH "DESCRIPTION"
  155. .IX Header "DESCRIPTION"
  156. The \*(C+ and Java languages provide function overloading, which means
  157. that you can write many functions with the same name, providing that
  158. each function takes parameters of different types. In order to be
  159. able to distinguish these similarly named functions \*(C+ and Java
  160. encode them into a low-level assembler name which uniquely identifies
  161. each different version. This process is known as \fImangling\fR. The
  162. \&\fBc++filt\fR
  163. [1]
  164. program does the inverse mapping: it decodes (\fIdemangles\fR) low-level
  165. names into user-level names so that they can be read.
  166. .PP
  167. Every alphanumeric word (consisting of letters, digits, underscores,
  168. dollars, or periods) seen in the input is a potential mangled name.
  169. If the name decodes into a \*(C+ name, the \*(C+ name replaces the
  170. low-level name in the output, otherwise the original word is output.
  171. In this way you can pass an entire assembler source file, containing
  172. mangled names, through \fBc++filt\fR and see the same source file
  173. containing demangled names.
  174. .PP
  175. You can also use \fBc++filt\fR to decipher individual symbols by
  176. passing them on the command line:
  177. .PP
  178. .Vb 1
  179. \& c++filt <symbol>
  180. .Ve
  181. .PP
  182. If no \fIsymbol\fR arguments are given, \fBc++filt\fR reads symbol
  183. names from the standard input instead. All the results are printed on
  184. the standard output. The difference between reading names from the
  185. command line versus reading names from the standard input is that
  186. command-line arguments are expected to be just mangled names and no
  187. checking is performed to separate them from surrounding text. Thus
  188. for example:
  189. .PP
  190. .Vb 1
  191. \& c++filt \-n _Z1fv
  192. .Ve
  193. .PP
  194. will work and demangle the name to \*(L"f()\*(R" whereas:
  195. .PP
  196. .Vb 1
  197. \& c++filt \-n _Z1fv,
  198. .Ve
  199. .PP
  200. will not work. (Note the extra comma at the end of the mangled
  201. name which makes it invalid). This command however will work:
  202. .PP
  203. .Vb 1
  204. \& echo _Z1fv, | c++filt \-n
  205. .Ve
  206. .PP
  207. and will display \*(L"f(),\*(R", i.e., the demangled name followed by a
  208. trailing comma. This behaviour is because when the names are read
  209. from the standard input it is expected that they might be part of an
  210. assembler source file where there might be extra, extraneous
  211. characters trailing after a mangled name. For example:
  212. .PP
  213. .Vb 1
  214. \& .type _Z1fv, @function
  215. .Ve
  216. .SH "OPTIONS"
  217. .IX Header "OPTIONS"
  218. .IP "\fB\-_\fR" 4
  219. .IX Item "-_"
  220. .PD 0
  221. .IP "\fB\-\-strip\-underscore\fR" 4
  222. .IX Item "--strip-underscore"
  223. .PD
  224. On some systems, both the C and \*(C+ compilers put an underscore in front
  225. of every name. For example, the C name \f(CW\*(C`foo\*(C'\fR gets the low-level
  226. name \f(CW\*(C`_foo\*(C'\fR. This option removes the initial underscore. Whether
  227. \&\fBc++filt\fR removes the underscore by default is target dependent.
  228. .IP "\fB\-n\fR" 4
  229. .IX Item "-n"
  230. .PD 0
  231. .IP "\fB\-\-no\-strip\-underscore\fR" 4
  232. .IX Item "--no-strip-underscore"
  233. .PD
  234. Do not remove the initial underscore.
  235. .IP "\fB\-p\fR" 4
  236. .IX Item "-p"
  237. .PD 0
  238. .IP "\fB\-\-no\-params\fR" 4
  239. .IX Item "--no-params"
  240. .PD
  241. When demangling the name of a function, do not display the types of
  242. the function's parameters.
  243. .IP "\fB\-t\fR" 4
  244. .IX Item "-t"
  245. .PD 0
  246. .IP "\fB\-\-types\fR" 4
  247. .IX Item "--types"
  248. .PD
  249. Attempt to demangle types as well as function names. This is disabled
  250. by default since mangled types are normally only used internally in
  251. the compiler, and they can be confused with non-mangled names. For example,
  252. a function called \*(L"a\*(R" treated as a mangled type name would be
  253. demangled to \*(L"signed char\*(R".
  254. .IP "\fB\-i\fR" 4
  255. .IX Item "-i"
  256. .PD 0
  257. .IP "\fB\-\-no\-verbose\fR" 4
  258. .IX Item "--no-verbose"
  259. .PD
  260. Do not include implementation details (if any) in the demangled
  261. output.
  262. .IP "\fB\-r\fR" 4
  263. .IX Item "-r"
  264. .PD 0
  265. .IP "\fB\-R\fR" 4
  266. .IX Item "-R"
  267. .IP "\fB\-\-recurse\-limit\fR" 4
  268. .IX Item "--recurse-limit"
  269. .IP "\fB\-\-no\-recurse\-limit\fR" 4
  270. .IX Item "--no-recurse-limit"
  271. .IP "\fB\-\-recursion\-limit\fR" 4
  272. .IX Item "--recursion-limit"
  273. .IP "\fB\-\-no\-recursion\-limit\fR" 4
  274. .IX Item "--no-recursion-limit"
  275. .PD
  276. Enables or disables a limit on the amount of recursion performed
  277. whilst demangling strings. Since the name mangling formats allow for
  278. an inifinite level of recursion it is possible to create strings whose
  279. decoding will exhaust the amount of stack space available on the host
  280. machine, triggering a memory fault. The limit tries to prevent this
  281. from happening by restricting recursion to 2048 levels of nesting.
  282. .Sp
  283. The default is for this limit to be enabled, but disabling it may be
  284. necessary in order to demangle truly complicated names. Note however
  285. that if the recursion limit is disabled then stack exhaustion is
  286. possible and any bug reports about such an event will be rejected.
  287. .Sp
  288. The \fB\-r\fR option is a synonym for the
  289. \&\fB\-\-no\-recurse\-limit\fR option. The \fB\-R\fR option is a
  290. synonym for the \fB\-\-recurse\-limit\fR option.
  291. .IP "\fB\-s\fR \fIformat\fR" 4
  292. .IX Item "-s format"
  293. .PD 0
  294. .IP "\fB\-\-format=\fR\fIformat\fR" 4
  295. .IX Item "--format=format"
  296. .PD
  297. \&\fBc++filt\fR can decode various methods of mangling, used by
  298. different compilers. The argument to this option selects which
  299. method it uses:
  300. .RS 4
  301. .ie n .IP """auto""" 4
  302. .el .IP "\f(CWauto\fR" 4
  303. .IX Item "auto"
  304. Automatic selection based on executable (the default method)
  305. .ie n .IP """gnu""" 4
  306. .el .IP "\f(CWgnu\fR" 4
  307. .IX Item "gnu"
  308. the one used by the \s-1GNU \*(C+\s0 compiler (g++)
  309. .ie n .IP """lucid""" 4
  310. .el .IP "\f(CWlucid\fR" 4
  311. .IX Item "lucid"
  312. the one used by the Lucid compiler (lcc)
  313. .ie n .IP """arm""" 4
  314. .el .IP "\f(CWarm\fR" 4
  315. .IX Item "arm"
  316. the one specified by the \*(C+ Annotated Reference Manual
  317. .ie n .IP """hp""" 4
  318. .el .IP "\f(CWhp\fR" 4
  319. .IX Item "hp"
  320. the one used by the \s-1HP\s0 compiler (aCC)
  321. .ie n .IP """edg""" 4
  322. .el .IP "\f(CWedg\fR" 4
  323. .IX Item "edg"
  324. the one used by the \s-1EDG\s0 compiler
  325. .ie n .IP """gnu\-v3""" 4
  326. .el .IP "\f(CWgnu\-v3\fR" 4
  327. .IX Item "gnu-v3"
  328. the one used by the \s-1GNU \*(C+\s0 compiler (g++) with the V3 \s-1ABI.\s0
  329. .ie n .IP """java""" 4
  330. .el .IP "\f(CWjava\fR" 4
  331. .IX Item "java"
  332. the one used by the \s-1GNU\s0 Java compiler (gcj)
  333. .ie n .IP """gnat""" 4
  334. .el .IP "\f(CWgnat\fR" 4
  335. .IX Item "gnat"
  336. the one used by the \s-1GNU\s0 Ada compiler (\s-1GNAT\s0).
  337. .RE
  338. .RS 4
  339. .RE
  340. .IP "\fB\-\-help\fR" 4
  341. .IX Item "--help"
  342. Print a summary of the options to \fBc++filt\fR and exit.
  343. .IP "\fB\-\-version\fR" 4
  344. .IX Item "--version"
  345. Print the version number of \fBc++filt\fR and exit.
  346. .IP "\fB@\fR\fIfile\fR" 4
  347. .IX Item "@file"
  348. Read command-line options from \fIfile\fR. The options read are
  349. inserted in place of the original @\fIfile\fR option. If \fIfile\fR
  350. does not exist, or cannot be read, then the option will be treated
  351. literally, and not removed.
  352. .Sp
  353. Options in \fIfile\fR are separated by whitespace. A whitespace
  354. character may be included in an option by surrounding the entire
  355. option in either single or double quotes. Any character (including a
  356. backslash) may be included by prefixing the character to be included
  357. with a backslash. The \fIfile\fR may itself contain additional
  358. @\fIfile\fR options; any such options will be processed recursively.
  359. .SH "FOOTNOTES"
  360. .IX Header "FOOTNOTES"
  361. .IP "1." 4
  362. MS-DOS does not allow \f(CW\*(C`+\*(C'\fR characters in file names, so on
  363. MS-DOS this program is named \fB\s-1CXXFILT\s0\fR.
  364. .SH "SEE ALSO"
  365. .IX Header "SEE ALSO"
  366. the Info entries for \fIbinutils\fR.
  367. .SH "COPYRIGHT"
  368. .IX Header "COPYRIGHT"
  369. Copyright (c) 1991\-2020 Free Software Foundation, Inc.
  370. .PP
  371. Permission is granted to copy, distribute and/or modify this document
  372. under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.3
  373. or any later version published by the Free Software Foundation;
  374. with no Invariant Sections, with no Front-Cover Texts, and with no
  375. Back-Cover Texts. A copy of the license is included in the
  376. section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".