[PATCH] D57083: llvm-symbolizer: Add support for -i and -inlines as aliases for -inlining
Douglas Yung via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 23 16:34:17 PST 2019
This revision was automatically updated to reflect the committed changes.
Closed by commit rL351999: [llvm-symbolizer] Add support for -i and -inlines as aliases for -inlining (authored by dyung, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D57083?vs=183082&id=183207#toc
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D57083/new/
https://reviews.llvm.org/D57083
Files:
llvm/trunk/docs/CommandGuide/llvm-symbolizer.rst
llvm/trunk/test/tools/llvm-symbolizer/coff-dwarf.test
llvm/trunk/test/tools/llvm-symbolizer/coff-exports.test
llvm/trunk/test/tools/llvm-symbolizer/flag-grouping.test
llvm/trunk/test/tools/llvm-symbolizer/sym.test
llvm/trunk/tools/llvm-symbolizer/llvm-symbolizer.cpp
Index: llvm/trunk/test/tools/llvm-symbolizer/coff-exports.test
===================================================================
--- llvm/trunk/test/tools/llvm-symbolizer/coff-exports.test
+++ llvm/trunk/test/tools/llvm-symbolizer/coff-exports.test
@@ -1,6 +1,12 @@
RUN: grep '^ADDR:' %s | sed -s 's/ADDR: //' \
RUN: | llvm-symbolizer --inlining --relative-address -obj="%p/Inputs/coff-exports.exe" \
RUN: | FileCheck %s
+RUN: grep '^ADDR:' %s | sed -s 's/ADDR: //' \
+RUN: | llvm-symbolizer --inlines --relative-address -obj="%p/Inputs/coff-exports.exe" \
+RUN: | FileCheck %s
+RUN: grep '^ADDR:' %s | sed -s 's/ADDR: //' \
+RUN: | llvm-symbolizer -i --relative-address -obj="%p/Inputs/coff-exports.exe" \
+RUN: | FileCheck %s
This test relies on UnDecorateSymbolName, which is Win32-only.
REQUIRES: system-windows
Index: llvm/trunk/test/tools/llvm-symbolizer/coff-dwarf.test
===================================================================
--- llvm/trunk/test/tools/llvm-symbolizer/coff-dwarf.test
+++ llvm/trunk/test/tools/llvm-symbolizer/coff-dwarf.test
@@ -1,6 +1,12 @@
RUN: grep '^ADDR:' %s | sed -s 's/ADDR: //' \
RUN: | llvm-symbolizer --inlining --relative-address -obj="%p/Inputs/coff-dwarf.exe" \
RUN: | FileCheck %s
+RUN: grep '^ADDR:' %s | sed -s 's/ADDR: //' \
+RUN: | llvm-symbolizer --inlines --relative-address -obj="%p/Inputs/coff-dwarf.exe" \
+RUN: | FileCheck %s
+RUN: grep '^ADDR:' %s | sed -s 's/ADDR: //' \
+RUN: | llvm-symbolizer -i --relative-address -obj="%p/Inputs/coff-dwarf.exe" \
+RUN: | FileCheck %s
This test relies on UnDecorateSymbolName, which is Windows-only.
REQUIRES: target-windows, system-windows
Index: llvm/trunk/test/tools/llvm-symbolizer/sym.test
===================================================================
--- llvm/trunk/test/tools/llvm-symbolizer/sym.test
+++ llvm/trunk/test/tools/llvm-symbolizer/sym.test
@@ -22,6 +22,10 @@
RUN: llvm-symbolizer -a -obj=%p/Inputs/addr.exe < %p/Inputs/addr.inp | FileCheck %s
RUN: llvm-symbolizer -inlining -print-address -pretty-print -obj=%p/Inputs/addr.exe < %p/Inputs/addr.inp | FileCheck -check-prefix="PRETTY" %s
RUN: llvm-symbolizer -inlining -print-address -p -obj=%p/Inputs/addr.exe < %p/Inputs/addr.inp | FileCheck -check-prefix="PRETTY" %s
+RUN: llvm-symbolizer -inlines -print-address -pretty-print -obj=%p/Inputs/addr.exe < %p/Inputs/addr.inp | FileCheck -check-prefix="PRETTY" %s
+RUN: llvm-symbolizer -inlines -print-address -p -obj=%p/Inputs/addr.exe < %p/Inputs/addr.inp | FileCheck -check-prefix="PRETTY" %s
+RUN: llvm-symbolizer -i -print-address -pretty-print -obj=%p/Inputs/addr.exe < %p/Inputs/addr.inp | FileCheck -check-prefix="PRETTY" %s
+RUN: llvm-symbolizer -i -print-address -p -obj=%p/Inputs/addr.exe < %p/Inputs/addr.inp | FileCheck -check-prefix="PRETTY" %s
RUN: echo "0x1" > %t.input
RUN: llvm-symbolizer -obj=%p/Inputs/zero < %t.input | FileCheck -check-prefix="ZERO" %s
Index: llvm/trunk/test/tools/llvm-symbolizer/flag-grouping.test
===================================================================
--- llvm/trunk/test/tools/llvm-symbolizer/flag-grouping.test
+++ llvm/trunk/test/tools/llvm-symbolizer/flag-grouping.test
@@ -1,4 +1,4 @@
-RUN: llvm-symbolizer -inlining -apfC -obj=%p/Inputs/addr.exe < %p/Inputs/addr.inp | FileCheck %s
+RUN: llvm-symbolizer -apCi -obj=%p/Inputs/addr.exe < %p/Inputs/addr.inp | FileCheck %s
CHECK: some text
CHECK: 0x40054d: inctwo
Index: llvm/trunk/tools/llvm-symbolizer/llvm-symbolizer.cpp
===================================================================
--- llvm/trunk/tools/llvm-symbolizer/llvm-symbolizer.cpp
+++ llvm/trunk/tools/llvm-symbolizer/llvm-symbolizer.cpp
@@ -58,6 +58,13 @@
static cl::opt<bool>
ClPrintInlining("inlining", cl::init(true),
cl::desc("Print all inlined frames for a given address"));
+static cl::alias
+ ClPrintInliningAliasI("i", cl::desc("Alias for -inlining"),
+ cl::NotHidden, cl::aliasopt(ClPrintInlining),
+ cl::Grouping);
+static cl::alias
+ ClPrintInliningAliasInlines("inlines", cl::desc("Alias for -inlining"),
+ cl::NotHidden, cl::aliasopt(ClPrintInlining));
// -basenames, -s
static cl::opt<bool> ClBasenames("basenames", cl::init(false),
Index: llvm/trunk/docs/CommandGuide/llvm-symbolizer.rst
===================================================================
--- llvm/trunk/docs/CommandGuide/llvm-symbolizer.rst
+++ llvm/trunk/docs/CommandGuide/llvm-symbolizer.rst
@@ -91,7 +91,7 @@
Don't print demangled function names.
-.. option:: -inlining
+.. option:: -inlining, -inlines, -i
If a source code location is in an inlined function, prints all the
inlnied frames. Defaults to true.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D57083.183207.patch
Type: text/x-patch
Size: 4784 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190124/8e156b6a/attachment-0001.bin>
More information about the llvm-commits
mailing list