[all-commits] [llvm/llvm-project] c4119d: [Clang][AMDGPU] Avoid Using `byval` for `ndrange_t...
Shilei Tian via All-commits
all-commits at lists.llvm.org
Fri Nov 15 12:13:55 PST 2024
Branch: refs/heads/users/shiltian/no-byval-amdgpu
Home: https://github.com/llvm/llvm-project
Commit: c4119d6abab8f9d734581e5b53223afe759498c0
https://github.com/llvm/llvm-project/commit/c4119d6abab8f9d734581e5b53223afe759498c0
Author: Shilei Tian <i at tianshilei.me>
Date: 2024-11-15 (Fri, 15 Nov 2024)
Changed paths:
M clang/lib/CodeGen/CGBuiltin.cpp
M clang/test/CodeGenOpenCL/amdgpu-enqueue-kernel.cl
Log Message:
-----------
[Clang][AMDGPU] Avoid Using `byval` for `ndrange_t` when emitting `__enqueue_kernel_basic`
AMDGPU disabled the use of `byval` for struct argument passing in commit
d77c620. However, when emitting `__enqueue_kernel_basic`, Clang still adds the
`byval` attribute by default. This PR introduces a target check to avoid
emitting the `byval` attribute unnecessarily.
FWIW, I’m not sure if it’s a good idea to emit the `byval` attribute by default
in this context. The way arguments are passed is highly target-dependent, and
making assumptions here doesn’t seem ideal.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list