aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/CompilerInvocation.cpp
diff options
context:
space:
mode:
authorDjordje Todorovic <djtodoro@cisco.com>2021-03-11 06:55:13 -0800
committerDjordje Todorovic <djtodoro@cisco.com>2021-03-25 05:29:42 -0700
commit8420a5332486c682c1aaddbcb58a571869d19832 (patch)
tree95a9a14a53b5ad2258d12c7407c81a11af7f3701 /clang/lib/Frontend/CompilerInvocation.cpp
parent5ab3bc0683c0ee7848b3fe991c35d73d0c9a603e (diff)
downloadllvm-8420a5332486c682c1aaddbcb58a571869d19832.zip
llvm-8420a5332486c682c1aaddbcb58a571869d19832.tar.gz
llvm-8420a5332486c682c1aaddbcb58a571869d19832.tar.bz2
[Debugify] Expose original debug info preservation check as CC1 option
In order to test the preservation of the original Debug Info metadata in your projects, a front end option could be very useful, since users usually report that a concrete entity (e.g. variable x, or function fn2()) is missing debug info. The [0] is an example of running the utility on GDB Project. This depends on: D82546 and D82545. Differential Revision: https://reviews.llvm.org/D82547
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
-rw-r--r--clang/lib/Frontend/CompilerInvocation.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/lib/Frontend/CompilerInvocation.cpp b/clang/lib/Frontend/CompilerInvocation.cpp
index 56aa4b4..490672b 100644
--- a/clang/lib/Frontend/CompilerInvocation.cpp
+++ b/clang/lib/Frontend/CompilerInvocation.cpp
@@ -1648,6 +1648,12 @@ bool CompilerInvocation::ParseCodeGenArgs(CodeGenOptions &Opts, ArgList &Args,
llvm::is_contained(DebugEntryValueArchs, T.getArch()))
Opts.EmitCallSiteInfo = true;
+ if (!Opts.EnableDIPreservationVerify && Opts.DIBugsReportFilePath.size()) {
+ Diags.Report(diag::warn_ignoring_verify_debuginfo_preserve_export)
+ << Opts.DIBugsReportFilePath;
+ Opts.DIBugsReportFilePath = "";
+ }
+
Opts.NewStructPathTBAA = !Args.hasArg(OPT_no_struct_path_tbaa) &&
Args.hasArg(OPT_new_struct_path_tbaa);
Opts.OptimizeSize = getOptimizationLevelSize(Args);