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

Thorsten via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sun Dec 18 10:17:39 PST 2022


tschuett added a comment.

In D140226#4003794 <https://reviews.llvm.org/D140226#4003794>, @jhuber6 wrote:

> In D140226#4003788 <https://reviews.llvm.org/D140226#4003788>, @tschuett wrote:
>
>> There are already SYCL specific attributes: https://reviews.llvm.org/D60455
>
> We could potentially merge these all into some generic attribute since they all do the same thing on a conceptual level. The unique thing about the existing `amdgpu_kernel` and corresponding `nvptx_kernel` is that they don't rely on the language options like `SYCL` or `CUDA`. Though, semantically those are definitely involved because the kernel itself is only meaningful to whatever runtime is going to load it (e.g. CUDA or HSA) but we can probably consider that separately to the compilation itself and just think of these as calling conventions.

But then you are maybe mixing two concepts. `kernel` is source code or AST feature. nvptx or AMDGPU are command line flags.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D140226



More information about the cfe-commits mailing list