[PATCH] D141375: [SYCL][OpenMP] Fix compilation errors for unsupported __bf16 intrinsics
Elizabeth Andrews via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Sep 7 15:44:46 PDT 2023
eandrews added inline comments.
================
Comment at: clang/lib/Sema/Sema.cpp:1978-1979
!Context.getTargetInfo().hasInt128Type()) ||
+ (Ty->isBFloat16Type() && !Context.getTargetInfo().hasBFloat16Type() &&
+ !LangOpts.CUDAIsDevice) ||
LongDoubleMismatched) {
----------------
tra wrote:
> @eandrews Do you recall what was the reason for *not* issuing the diagnostic on the GPU side?
>
> It appears to do the opposite to what the patch description says. We're supposed to `emit error for unsupported type __bf16 in device code`, but instead we specifically ignore it during GPU-side compilation. What am I missing?
>
>
>
I don't recall the specifics but I think CUDA had code handling __bf16 differently and this change broke a test with CUDA diagnostics and so I excluded it from the patch. I could try removing this check and seeing what breaks if you'd like.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D141375/new/
https://reviews.llvm.org/D141375
More information about the cfe-commits
mailing list