]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - usr.bin/clang/llvm-symbolizer/llvm-symbolizer.1
Fix memory disclosure vulnerability in libalias.
[FreeBSD/FreeBSD.git] / usr.bin / clang / llvm-symbolizer / llvm-symbolizer.1
1 .\" $FreeBSD$
2 .\" Man page generated from reStructuredText.
3 .
4 .TH "LLVM-SYMBOLIZER" "1" "2018-08-02" "7" "LLVM"
5 .SH NAME
6 llvm-symbolizer \- convert addresses into source code locations
7 .
8 .nr rst2man-indent-level 0
9 .
10 .de1 rstReportMargin
11 \\$1 \\n[an-margin]
12 level \\n[rst2man-indent-level]
13 level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
14 -
15 \\n[rst2man-indent0]
16 \\n[rst2man-indent1]
17 \\n[rst2man-indent2]
18 ..
19 .de1 INDENT
20 .\" .rstReportMargin pre:
21 . RS \\$1
22 . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
23 . nr rst2man-indent-level +1
24 .\" .rstReportMargin post:
25 ..
26 .de UNINDENT
27 . RE
28 .\" indent \\n[an-margin]
29 .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
30 .nr rst2man-indent-level -1
31 .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
32 .in \\n[rst2man-indent\\n[rst2man-indent-level]]u
33 ..
34 .SH SYNOPSIS
35 .sp
36 \fBllvm\-symbolizer\fP [options]
37 .SH DESCRIPTION
38 .sp
39 \fBllvm\-symbolizer\fP reads object file names and addresses from standard
40 input and prints corresponding source code locations to standard output.
41 If object file is specified in command line, \fBllvm\-symbolizer\fP
42 processes only addresses from standard input, the rest is output verbatim.
43 This program uses debug info sections and symbol table in the object files.
44 .SH EXAMPLE
45 .INDENT 0.0
46 .INDENT 3.5
47 .sp
48 .nf
49 .ft C
50 $ cat addr.txt
51 a.out 0x4004f4
52 /tmp/b.out 0x400528
53 /tmp/c.so 0x710
54 /tmp/mach_universal_binary:i386 0x1f84
55 /tmp/mach_universal_binary:x86_64 0x100000f24
56 $ llvm\-symbolizer < addr.txt
57 main
58 /tmp/a.cc:4
59
60 f(int, int)
61 /tmp/b.cc:11
62
63 h_inlined_into_g
64 /tmp/header.h:2
65 g_inlined_into_f
66 /tmp/header.h:7
67 f_inlined_into_main
68 /tmp/source.cc:3
69 main
70 /tmp/source.cc:8
71
72 _main
73 /tmp/source_i386.cc:8
74
75 _main
76 /tmp/source_x86_64.cc:8
77 $ cat addr2.txt
78 0x4004f4
79 0x401000
80 $ llvm\-symbolizer \-obj=a.out < addr2.txt
81 main
82 /tmp/a.cc:4
83
84 foo(int)
85 /tmp/a.cc:12
86 $cat addr.txt
87 0x40054d
88 $llvm\-symbolizer \-inlining \-print\-address \-pretty\-print \-obj=addr.exe < addr.txt
89 0x40054d: inc at /tmp/x.c:3:3
90  (inlined by) main at /tmp/x.c:9:0
91 $llvm\-symbolizer \-inlining \-pretty\-print \-obj=addr.exe < addr.txt
92 inc at /tmp/x.c:3:3
93  (inlined by) main at /tmp/x.c:9:0
94 .ft P
95 .fi
96 .UNINDENT
97 .UNINDENT
98 .SH OPTIONS
99 .INDENT 0.0
100 .TP
101 .B \-obj
102 Path to object file to be symbolized.
103 .UNINDENT
104 .INDENT 0.0
105 .TP
106 .B \-functions=[none|short|linkage]
107 Specify the way function names are printed (omit function name,
108 print short function name, or print full linkage name, respectively).
109 Defaults to \fBlinkage\fP\&.
110 .UNINDENT
111 .INDENT 0.0
112 .TP
113 .B \-use\-symbol\-table
114 Prefer function names stored in symbol table to function names
115 in debug info sections. Defaults to true.
116 .UNINDENT
117 .INDENT 0.0
118 .TP
119 .B \-demangle
120 Print demangled function names. Defaults to true.
121 .UNINDENT
122 .INDENT 0.0
123 .TP
124 .B \-inlining
125 If a source code location is in an inlined function, prints all the
126 inlnied frames. Defaults to true.
127 .UNINDENT
128 .INDENT 0.0
129 .TP
130 .B \-default\-arch
131 If a binary contains object files for multiple architectures (e.g. it is a
132 Mach\-O universal binary), symbolize the object file for a given architecture.
133 You can also specify architecture by writing \fBbinary_name:arch_name\fP in the
134 input (see example above). If architecture is not specified in either way,
135 address will not be symbolized. Defaults to empty string.
136 .UNINDENT
137 .INDENT 0.0
138 .TP
139 .B \-dsym\-hint=<path/to/file.dSYM>
140 (Darwin\-only flag). If the debug info for a binary isn\(aqt present in the default
141 location, look for the debug info at the .dSYM path provided via the
142 \fB\-dsym\-hint\fP flag. This flag can be used multiple times.
143 .UNINDENT
144 .INDENT 0.0
145 .TP
146 .B \-print\-address
147 Print address before the source code location. Defaults to false.
148 .UNINDENT
149 .INDENT 0.0
150 .TP
151 .B \-pretty\-print
152 Print human readable output. If \fB\-inlining\fP is specified, enclosing scope is
153 prefixed by (inlined by). Refer to listed examples.
154 .UNINDENT
155 .SH EXIT STATUS
156 .sp
157 \fBllvm\-symbolizer\fP returns 0. Other exit codes imply internal program error.
158 .SH AUTHOR
159 Maintained by The LLVM Team (http://llvm.org/).
160 .SH COPYRIGHT
161 2003-2018, LLVM Project
162 .\" Generated by docutils manpage writer.
163 .