Skip to content

Commit d389513

Browse files
committed
Address Comments....
1 parent 9542e89 commit d389513

File tree

4 files changed

+268
-661
lines changed

4 files changed

+268
-661
lines changed

llvm/docs/CommandGuide/llvm-symbolizer.rst

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -209,11 +209,30 @@ Example 7 - Addresses as symbol names:
209209
210210
Example 8 - :option:`--skip-line-zero` output for an address with no line correspondence (an address associated with line zero):
211211

212+
.. code-block:: c
213+
214+
// test.c
215+
int foo = 0;
216+
int x = 1234;
217+
int main() {
218+
if (x)
219+
return foo;
220+
else
221+
return x;
222+
}
223+
224+
These files are built as follows:
225+
226+
.. code-block:: console
227+
228+
$ clang -g -O2 -S test.c -o test.s
229+
$ llvm-mc -filetype=obj -triple=x86_64-unknown-linux test.s -o test.o
230+
212231
.. code-block:: console
213232
214-
$ llvm-symbolizer --obj=test.elf --skip-line-zero 0xa
233+
$ llvm-symbolizer --obj=test.o --skip-line-zero 0xa
215234
main
216-
/tmp/test/main.c:4:6 (approximate)
235+
/tmp/test.c:5:7 (approximate)
217236
218237
OPTIONS
219238
-------

llvm/test/tools/llvm-symbolizer/approximate-line-generated.s

Lines changed: 0 additions & 170 deletions
This file was deleted.

0 commit comments

Comments
 (0)