aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAleksei Vetrov <vvvvvv@google.com>2023-09-08 15:19:25 +0100
committerGiuliano Procida <gprocida@google.com>2023-09-12 09:31:53 +0100
commit0d4705931faa4f17448b36dd04ca19659eb512f8 (patch)
treed7c1b937c12b32dd50856d79d5d9c08edaaf3214
parent7bb30801bfd8df4881202cc0b03fb0e785668f7f (diff)
downloadstg-0d4705931faa4f17448b36dd04ca19659eb512f8.tar.gz
Add `--symbol-filter` option as synonym for `--symbols`
The new name is used to emphasise that this option takes not only a list of symbols but filter expression. PiperOrigin-RevId: 563744938 Change-Id: I7d9634fbfcac58c016eb9ca89d7a31f1ba4ec1e4
-rw-r--r--doc/stg.md2
-rw-r--r--stg.cc3
2 files changed, 3 insertions, 2 deletions
diff --git a/doc/stg.md b/doc/stg.md
index 88df9b5..d6ddd5f 100644
--- a/doc/stg.md
+++ b/doc/stg.md
@@ -14,7 +14,7 @@ stg
[-i|--info]
[-d|--keep-duplicates]
[-t|--types]
- [-S|--symbols <filter>]
+ [-S|--symbols|--symbol-filter <filter>]
[--skip-dwarf]
[-a|--abi|-b|--btf|-e|--elf|-s|--stg] [file] ...
[{-o|--output} {filename|-}] ...
diff --git a/stg.cc b/stg.cc
index 8948ac0..e699d5a 100644
--- a/stg.cc
+++ b/stg.cc
@@ -127,6 +127,7 @@ int main(int argc, char* argv[]) {
{"keep-duplicates", no_argument, nullptr, 'd' },
{"types", no_argument, nullptr, 't' },
{"symbols", required_argument, nullptr, 'S' },
+ {"symbol-filter", required_argument, nullptr, 'S' },
{"abi", no_argument, nullptr, 'a' },
{"btf", no_argument, nullptr, 'b' },
{"elf", no_argument, nullptr, 'e' },
@@ -141,7 +142,7 @@ int main(int argc, char* argv[]) {
<< " [-i|--info]\n"
<< " [-d|--keep-duplicates]\n"
<< " [-t|--types]\n"
- << " [-S|--symbols <filter>]\n"
+ << " [-S|--symbols|--symbol-filter <filter>]\n"
<< " [--skip-dwarf]\n"
<< " [-a|--abi|-b|--btf|-e|--elf|-s|--stg] [file] ...\n"
<< " [{-o|--output} {filename|-}] ...\n"