[PATCH] D140226: [NVPTX] Introduce attribute to mark kernels without a language mode

Joseph Huber via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Mar 24 11:18:19 PDT 2023


jhuber6 updated this revision to Diff 508170.
jhuber6 added a comment.

Updating to simply add an entirely new attribute again. The existing
`CUDAGlobal` attribute does what we want, but it's also highly coupled with the
CUDA language. This made it pretty much impossible to find a way to re-use it
without breaking existing functionality. The amount of code duplicated is
minimal and this is required to be able to emit a callable kernel targeting
NVPTX directly. I'd like to use this for my ongoing GPU `libc` project so I'd
appreciate someone looking at this again.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D140226/new/

https://reviews.llvm.org/D140226

Files:
  clang/include/clang/Basic/Attr.td
  clang/lib/CodeGen/TargetInfo.cpp
  clang/lib/Sema/SemaDeclAttr.cpp
  clang/test/CodeGen/nvptx_attributes.c
  clang/test/Misc/pragma-attribute-supported-attributes-list.test

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D140226.508170.patch
Type: text/x-patch
Size: 4350 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230324/4f3afeef/attachment.bin>


More information about the cfe-commits mailing list