From 648f4cad528dbcc2acfa7a7f6a35106777a56c68 Mon Sep 17 00:00:00 2001 From: Justin Lebar Date: Fri, 3 Nov 2017 02:30:00 +0000 Subject: [PATCH] [CUDA] Mark CUDA as a no-errno platform. Summary: CUDA doesn't support errno at all, so this is the right thing -- or at least, in the right direction. But also, this unbreaks the CUDA test-suite math tests [0] after D39481. __cuda_cmath.h forwards nexttoward() to __builtin_nexttoward, which, after that patch, was lowering to a libcall that doesn't exist in NVPTX. [0] http://lab.llvm.org:8011/builders/clang-cuda-build/builds/14999 Reviewers: tra Subscribers: sanjoy, cfe-commits Differential Revision: https://reviews.llvm.org/D39586 llvm-svn: 317297 --- clang/lib/Driver/ToolChains/Cuda.h | 1 + 1 file changed, 1 insertion(+) diff --git a/clang/lib/Driver/ToolChains/Cuda.h b/clang/lib/Driver/ToolChains/Cuda.h index 414c944..3101cb3 100644 --- a/clang/lib/Driver/ToolChains/Cuda.h +++ b/clang/lib/Driver/ToolChains/Cuda.h @@ -157,6 +157,7 @@ public: bool isPICDefaultForced() const override { return false; } bool SupportsProfiling() const override { return false; } bool SupportsObjCGC() const override { return false; } + bool IsMathErrnoDefault() const override { return false; } void AddCudaIncludeArgs(const llvm::opt::ArgList &DriverArgs, llvm::opt::ArgStringList &CC1Args) const override; -- 2.7.4