summaryrefslogtreecommitdiffstats
path: root/gnu/llvm/lib/CodeGen/ParallelCG.cpp
diff options
context:
space:
mode:
authorpatrick <patrick@openbsd.org>2019-01-27 16:42:12 +0000
committerpatrick <patrick@openbsd.org>2019-01-27 16:42:12 +0000
commitb773203fb58f3ef282fb69c832d8710cab5bc82d (patch)
treee75913f147570fbd75169647b144df85b88a038c /gnu/llvm/lib/CodeGen/ParallelCG.cpp
parenttweak errno in previous (diff)
downloadwireguard-openbsd-b773203fb58f3ef282fb69c832d8710cab5bc82d.tar.xz
wireguard-openbsd-b773203fb58f3ef282fb69c832d8710cab5bc82d.zip
Import LLVM 7.0.1 release including clang, lld and lldb.
Diffstat (limited to 'gnu/llvm/lib/CodeGen/ParallelCG.cpp')
-rw-r--r--gnu/llvm/lib/CodeGen/ParallelCG.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/gnu/llvm/lib/CodeGen/ParallelCG.cpp b/gnu/llvm/lib/CodeGen/ParallelCG.cpp
index ff8680a0540..bc3f2a6e9b5 100644
--- a/gnu/llvm/lib/CodeGen/ParallelCG.cpp
+++ b/gnu/llvm/lib/CodeGen/ParallelCG.cpp
@@ -30,7 +30,7 @@ static void codegen(Module *M, llvm::raw_pwrite_stream &OS,
TargetMachine::CodeGenFileType FileType) {
std::unique_ptr<TargetMachine> TM = TMFactory();
legacy::PassManager CodeGenPasses;
- if (TM->addPassesToEmitFile(CodeGenPasses, OS, FileType))
+ if (TM->addPassesToEmitFile(CodeGenPasses, OS, nullptr, FileType))
report_fatal_error("Failed to setup codegen");
CodeGenPasses.run(*M);
}
@@ -44,7 +44,7 @@ std::unique_ptr<Module> llvm::splitCodeGen(
if (OSs.size() == 1) {
if (!BCOSs.empty())
- WriteBitcodeToFile(M.get(), *BCOSs[0]);
+ WriteBitcodeToFile(*M, *BCOSs[0]);
codegen(M.get(), *OSs[0], TMFactory, FileType);
return M;
}
@@ -66,7 +66,7 @@ std::unique_ptr<Module> llvm::splitCodeGen(
// FIXME: Provide a more direct way to do this in LLVM.
SmallString<0> BC;
raw_svector_ostream BCOS(BC);
- WriteBitcodeToFile(MPart.get(), BCOS);
+ WriteBitcodeToFile(*MPart, BCOS);
if (!BCOSs.empty()) {
BCOSs[ThreadCount]->write(BC.begin(), BC.size());