Skip to content

Commit 84292e9

Browse files
author
Hugh Delaney
committed
Change behaviour so that cuda TC only has mathErrnoDefault for OFK_SYCL
1 parent d7097cb commit 84292e9

File tree

1 file changed

+3
-0
lines changed
  • clang/lib/Driver/ToolChains

1 file changed

+3
-0
lines changed

clang/lib/Driver/ToolChains/Cuda.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,9 @@ class LLVM_LIBRARY_VISIBILITY CudaToolChain : public ToolChain {
184184
void adjustDebugInfoKind(codegenoptions::DebugInfoKind &DebugInfoKind,
185185
const llvm::opt::ArgList &Args) const override;
186186

187+
// math-errno should be the default for SYCL but not other OFK using CUDA TC
188+
bool IsMathErrnoDefault() const override { return OK == Action::OFK_SYCL; }
189+
187190
void AddCudaIncludeArgs(const llvm::opt::ArgList &DriverArgs,
188191
llvm::opt::ArgStringList &CC1Args) const override;
189192

0 commit comments

Comments
 (0)