[clang] [Clang] Fix sema checks thinking kernels aren't kernels (PR #104460)
Joseph Huber via cfe-commits
cfe-commits at lists.llvm.org
Thu Aug 15 08:59:37 PDT 2024
================
@@ -7147,7 +7147,9 @@ void Sema::ProcessDeclAttributeList(
// good to have a way to specify "these attributes must appear as a group",
// for these. Additionally, it would be good to have a way to specify "these
// attribute must never appear as a group" for attributes like cold and hot.
- if (!D->hasAttr<OpenCLKernelAttr>()) {
----------------
jhuber6 wrote:
It doesn't check OpenCL attributes, it checks everything that's not an OpenCL kernel. That's why this currently causes errors. If you want I could put `&& LangOpt.IsOpenCL` but that causes other tests to fail so this was the less invasive option.
https://github.com/llvm/llvm-project/pull/104460
More information about the cfe-commits
mailing list