aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/CreateInvocationFromCommandLine.cpp
diff options
context:
space:
mode:
authorAlexandre Ganea <alexandre.ganea@ubisoft.com>2020-06-18 08:57:50 -0400
committerAlexandre Ganea <alexandre.ganea@ubisoft.com>2020-06-18 09:17:14 -0400
commit89ea0b05207d45c145fb525df554b3b986ae379b (patch)
treeb7eb532a2dfdfb9453963471f595e34a02f9e74d /clang/lib/Frontend/CreateInvocationFromCommandLine.cpp
parent24eff42ba4b85eaa5429e8efe9bd2070d34ba1f7 (diff)
downloadllvm-89ea0b05207d45c145fb525df554b3b986ae379b.zip
llvm-89ea0b05207d45c145fb525df554b3b986ae379b.tar.gz
llvm-89ea0b05207d45c145fb525df554b3b986ae379b.tar.bz2
[MC] Pass down argv0 & cc1 cmd-line to the back-end and store in MCTargetOptions
When targetting CodeView, the goal is to store argv0 & cc1 cmd-line in the emitted .OBJ, in order to allow a reproducer from the .OBJ alone. This patch is to simplify https://reviews.llvm.org/D80833
Diffstat (limited to 'clang/lib/Frontend/CreateInvocationFromCommandLine.cpp')
-rw-r--r--clang/lib/Frontend/CreateInvocationFromCommandLine.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Frontend/CreateInvocationFromCommandLine.cpp b/clang/lib/Frontend/CreateInvocationFromCommandLine.cpp
index 18c4814..1d5a6c06 100644
--- a/clang/lib/Frontend/CreateInvocationFromCommandLine.cpp
+++ b/clang/lib/Frontend/CreateInvocationFromCommandLine.cpp
@@ -93,7 +93,7 @@ std::unique_ptr<CompilerInvocation> clang::createInvocationFromCommandLine(
if (CC1Args)
*CC1Args = {CCArgs.begin(), CCArgs.end()};
auto CI = std::make_unique<CompilerInvocation>();
- if (!CompilerInvocation::CreateFromArgs(*CI, CCArgs, *Diags) &&
+ if (!CompilerInvocation::CreateFromArgs(*CI, CCArgs, *Diags, Args[0]) &&
!ShouldRecoverOnErorrs)
return nullptr;
return CI;