summaryrefslogtreecommitdiffstats
path: root/clang/lib/Frontend/CompilerInvocation.cpp
diff options
context:
space:
mode:
authorAlexey Bataev <a.bataev@hotmail.com>2018-09-05 17:10:30 +0000
committerAlexey Bataev <a.bataev@hotmail.com>2018-09-05 17:10:30 +0000
commit33c137bf0c92d071fc52b31445174e27355ab27d (patch)
tree24f83e857f624df208ce399a99d0500de68ba56e /clang/lib/Frontend/CompilerInvocation.cpp
parentbc555237a4cee9b25d0681ecbc1603a089c7421c (diff)
downloadbcm5719-llvm-33c137bf0c92d071fc52b31445174e27355ab27d.tar.gz
bcm5719-llvm-33c137bf0c92d071fc52b31445174e27355ab27d.zip
[OPENMP][NVPTX] Disable runtime-type info for CUDA devices.
RTTI is not supported by the NVPTX target. llvm-svn: 341483
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
-rw-r--r--clang/lib/Frontend/CompilerInvocation.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/lib/Frontend/CompilerInvocation.cpp b/clang/lib/Frontend/CompilerInvocation.cpp
index 5210314493d..7a0e78fba63 100644
--- a/clang/lib/Frontend/CompilerInvocation.cpp
+++ b/clang/lib/Frontend/CompilerInvocation.cpp
@@ -2650,6 +2650,11 @@ static void ParseLangArgs(LangOptions &Opts, ArgList &Args, InputKind IK,
Opts.Exceptions = 0;
Opts.CXXExceptions = 0;
}
+ // NVPTX does not support RTTI.
+ if (Opts.OpenMPIsDevice && T.isNVPTX()) {
+ Opts.RTTI = 0;
+ Opts.RTTIData = 0;
+ }
// Get the OpenMP target triples if any.
if (Arg *A = Args.getLastArg(options::OPT_fopenmp_targets_EQ)) {
OpenPOWER on IntegriCloud