We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 55957ad commit a4f4fa9Copy full SHA for a4f4fa9
clang/lib/Sema/Sema.cpp
@@ -1753,7 +1753,12 @@ void Sema::checkDeviceDecl(const ValueDecl *D, SourceLocation Loc) {
1753
if (Ty->isDependentType())
1754
return;
1755
1756
- if ((Ty->isFloat16Type() && !Context.getTargetInfo().hasFloat16Type()) ||
+ auto IsSYCLDeviceCuda = getLangOpts().SYCLIsDevice &&
1757
+ Context.getTargetInfo().getTriple().isNVPTX();
1758
+ if ((Ty->isFloat16Type() && !Context.getTargetInfo().hasFloat16Type() &&
1759
+ // Disable check for SYCL CUDA BE until FP16 support is properly
1760
+ // reported there (issue#1799)
1761
+ !IsSYCLDeviceCuda) ||
1762
((Ty->isFloat128Type() ||
1763
(Ty->isRealFloatingType() && Context.getTypeSize(Ty) == 128)) &&
1764
!Context.getTargetInfo().hasFloat128Type()) ||
0 commit comments