diff options
author | Amy Huang <akhuang@google.com> | 2020-01-13 15:54:54 -0800 |
---|---|---|
committer | Amy Huang <akhuang@google.com> | 2020-01-13 15:59:03 -0800 |
commit | 53539bb032d162e0147c0e9650a5d1c7ca77dae0 (patch) | |
tree | 85b602a6fc5d07957698fd59f49f3036c4616f67 /clang/lib/Frontend/CompilerInvocation.cpp | |
parent | c7748404920b3674e79059cbbe73b6041a214444 (diff) | |
download | llvm-53539bb032d162e0147c0e9650a5d1c7ca77dae0.zip llvm-53539bb032d162e0147c0e9650a5d1c7ca77dae0.tar.gz llvm-53539bb032d162e0147c0e9650a5d1c7ca77dae0.tar.bz2 |
[DebugInfo] Add another level to DebugInfoKind called Constructor
The option will limit debug info by only emitting complete class
type information when its constructor is emitted.
This patch changes comparisons with LimitedDebugInfo to use the new
level instead.
Differential Revision: https://reviews.llvm.org/D72427
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
-rw-r--r-- | clang/lib/Frontend/CompilerInvocation.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/Frontend/CompilerInvocation.cpp b/clang/lib/Frontend/CompilerInvocation.cpp index 4743d4f..e1e5956 100644 --- a/clang/lib/Frontend/CompilerInvocation.cpp +++ b/clang/lib/Frontend/CompilerInvocation.cpp @@ -731,6 +731,7 @@ static bool ParseCodeGenArgs(CodeGenOptions &Opts, ArgList &Args, InputKind IK, llvm::StringSwitch<unsigned>(A->getValue()) .Case("line-tables-only", codegenoptions::DebugLineTablesOnly) .Case("line-directives-only", codegenoptions::DebugDirectivesOnly) + .Case("constructor", codegenoptions::DebugInfoConstructor) .Case("limited", codegenoptions::LimitedDebugInfo) .Case("standalone", codegenoptions::FullDebugInfo) .Default(~0U); @@ -787,8 +788,7 @@ static bool ParseCodeGenArgs(CodeGenOptions &Opts, ArgList &Args, InputKind IK, llvm::Triple::arm, llvm::Triple::armeb}; llvm::Triple T(TargetOpts.Triple); - if (Opts.OptimizationLevel > 0 && - Opts.getDebugInfo() >= codegenoptions::LimitedDebugInfo && + if (Opts.OptimizationLevel > 0 && Opts.hasReducedDebugInfo() && llvm::is_contained(DebugEntryValueArchs, T.getArch())) Opts.EnableDebugEntryValues = Args.hasArg(OPT_femit_debug_entry_values); |