Skip to content

Commit da43861

Browse files
committed
[OpenMP][libomptarget] Suppress C++ 11 related warnings when building libomptarget-nvptx bitcode library, by Doru Bercea.
Summary: Pass -std=c++11 flag to compiler to suppress C++ 11 related warnings when building NVPTX bitcode library. Reviewers: ABataev, caomhin, Hahnfeld Reviewed By: ABataev, Hahnfeld Subscribers: jdoerfert, Hahnfeld, jholewinski, mgorny, guansong, openmp-commits Tags: #openmp Differential Revision: https://reviews.llvm.org/D55772 llvm-svn: 366438
1 parent a44b216 commit da43861

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

openmp/libomptarget/cmake/Modules/LibomptargetNVPTXBitcodeLibrary.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ endfunction()
7878

7979
# These flags are required to emit LLVM Bitcode. We check them together because
8080
# if any of them are not supported, there is no point in finding out which are.
81-
set(compiler_flags_required -emit-llvm -O1 --cuda-device-only --cuda-path=${CUDA_TOOLKIT_ROOT_DIR})
81+
set(compiler_flags_required -emit-llvm -O1 --cuda-device-only -std=c++11 --cuda-path=${CUDA_TOOLKIT_ROOT_DIR})
8282
set(compiler_flags_required_src "extern \"C\" __device__ int thread() { return threadIdx.x; }")
8383
check_bitcode_compilation(LIBOMPTARGET_NVPTX_CUDA_COMPILER_SUPPORTS_FLAGS_REQUIRED "${compiler_flags_required_src}" ${compiler_flags_required})
8484

0 commit comments

Comments
 (0)