aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/CodeGen/CodeGenModule.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/CodeGen/CodeGenModule.cpp')
-rw-r--r--clang/lib/CodeGen/CodeGenModule.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp
index 323823c..f1ddaa8 100644
--- a/clang/lib/CodeGen/CodeGenModule.cpp
+++ b/clang/lib/CodeGen/CodeGenModule.cpp
@@ -582,6 +582,11 @@ void CodeGenModule::createOpenCLRuntime() {
}
void CodeGenModule::createOpenMPRuntime() {
+ if (!LangOpts.OMPHostIRFile.empty() &&
+ !llvm::sys::fs::exists(LangOpts.OMPHostIRFile))
+ Diags.Report(diag::err_omp_host_ir_file_not_found)
+ << LangOpts.OMPHostIRFile;
+
// Select a specialized code generation class based on the target, if any.
// If it does not exist use the default implementation.
switch (getTriple().getArch()) {