diff options
author | Victor Lomuller <victor@codeplay.com> | 2025-07-09 14:52:06 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-07-09 13:52:06 +0100 |
commit | 27c9b55659c99fad4583fb6fa29dd079ea8b9582 (patch) | |
tree | fa045fbce68d2f5eb0ddfc8a386c9c8d5537bbc3 /clang/lib/Frontend/CompilerInstance.cpp | |
parent | 3877039fd1d09f87f13fdf64c544eafcfc09c650 (diff) | |
download | llvm-27c9b55659c99fad4583fb6fa29dd079ea8b9582.zip llvm-27c9b55659c99fad4583fb6fa29dd079ea8b9582.tar.gz llvm-27c9b55659c99fad4583fb6fa29dd079ea8b9582.tar.bz2 |
[SPIRV] Add more id and range builtIns (#143909)
The patch adds intrinsics and lowering logic for GlobalSize,
GlobalOffset, SubgroupMaxSize, NumWorkgroups, WorkgroupSize,
WorkgroupId, LocalInvocationId, GlobalInvocationId, SubgroupSize,
NumSubgroups, SubgroupId and SubgroupLocalInvocationId SPIR-V builtins.
The patch also extend spv_thread_id, spv_group_id and
spv_thread_id_in_group to return anyint rather than i32. This allows the
intrinsics to support the opencl environment.
For each of the intrinsics, new clang builtins were added as well as a
binding for the SPIR-V "friendly" format. The original format doesn't
define such binding (uses global variables) but it is not possible to
express the Input SC which is normally required by the environement
specs, and using builtin functions is the most usual approach for other
backend and programming models.
Diffstat (limited to 'clang/lib/Frontend/CompilerInstance.cpp')
0 files changed, 0 insertions, 0 deletions