aboutsummaryrefslogtreecommitdiff
path: root/llvm/tools/llvm-symbolizer/Opts.td
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/tools/llvm-symbolizer/Opts.td')
-rw-r--r--llvm/tools/llvm-symbolizer/Opts.td27
1 files changed, 18 insertions, 9 deletions
diff --git a/llvm/tools/llvm-symbolizer/Opts.td b/llvm/tools/llvm-symbolizer/Opts.td
index ac23639f130e..6026e24d6ffa 100644
--- a/llvm/tools/llvm-symbolizer/Opts.td
+++ b/llvm/tools/llvm-symbolizer/Opts.td
@@ -1,17 +1,20 @@
include "llvm/Option/OptParser.td"
multiclass B<string name, string help1, string help2> {
- def NAME: Flag<["--", "-"], name>, HelpText<help1>;
- def no_ # NAME: Flag<["--", "-"], "no-" # name>, HelpText<help2>;
+ def NAME: Flag<["--"], name>, HelpText<help1>;
+ def no_ # NAME: Flag<["--"], "no-" # name>, HelpText<help2>;
}
multiclass Eq<string name, string help> {
- def NAME #_EQ : Joined<["--", "-"], name #"=">,
+ def NAME #_EQ : Joined<["--"], name #"=">,
HelpText<help>;
- def : Separate<["--", "-"], name>, Alias<!cast<Joined>(NAME #_EQ)>;
+ def : Separate<["--"], name>, Alias<!cast<Joined>(NAME #_EQ)>;
}
-class F<string name, string help>: Flag<["--", "-"], name>, HelpText<help>;
+class F<string name, string help>: Flag<["--"], name>, HelpText<help>;
+
+def grp_mach_o : OptionGroup<"kind">,
+ HelpText<"llvm-symbolizer Mach-O Specific Options">;
def addresses : F<"addresses", "Show address before line information">;
defm adjust_vma
@@ -19,13 +22,19 @@ defm adjust_vma
MetaVarName<"<offset>">;
def basenames : Flag<["--"], "basenames">, HelpText<"Strip directory names from paths">;
defm debug_file_directory : Eq<"debug-file-directory", "Path to directory where to look for debug files">, MetaVarName<"<dir>">;
-defm default_arch : Eq<"default-arch", "Default architecture (for multi-arch objects)">;
+defm default_arch
+ : Eq<"default-arch", "Default architecture (for multi-arch objects)">,
+ Group<grp_mach_o>;
defm demangle : B<"demangle", "Demangle function names", "Don't demangle function names">;
def functions : F<"functions", "Print function name for a given address">;
def functions_EQ : Joined<["--"], "functions=">, HelpText<"Print function name for a given address">, Values<"none,short,linkage">;
def help : F<"help", "Display this help">;
defm dwp : Eq<"dwp", "Path to DWP file to be use for any split CUs">, MetaVarName<"<file>">;
-defm dsym_hint : Eq<"dsym-hint", "Path to .dSYM bundles to search for debug info for the object files">, MetaVarName<"<dir>">;
+defm dsym_hint
+ : Eq<"dsym-hint",
+ "Path to .dSYM bundles to search for debug info for the object files">,
+ MetaVarName<"<dir>">,
+ Group<grp_mach_o>;
defm fallback_debug_path : Eq<"fallback-debug-path", "Fallback path for debug binaries">, MetaVarName<"<dir>">;
defm inlines : B<"inlines", "Print all inlined frames for a given address",
"Do not print inlined frames">;
@@ -33,9 +42,9 @@ defm obj
: Eq<"obj", "Path to object file to be symbolized (if not provided, "
"object file should be specified for each input line)">, MetaVarName<"<file>">;
defm output_style
- : Eq<"output-style", "Specify print style. Supported styles: LLVM, GNU">,
+ : Eq<"output-style", "Specify print style. Supported styles: LLVM, GNU, JSON">,
MetaVarName<"style">,
- Values<"LLVM,GNU">;
+ Values<"LLVM,GNU,JSON">;
def pretty_print : F<"pretty-print", "Make the output more human friendly">;
defm print_source_context_lines : Eq<"print-source-context-lines", "Print N lines of source file context">;
def relative_address : F<"relative-address", "Interpret addresses as addresses relative to the image base">;