[all-commits] [llvm/llvm-project] c48f66: [Clang][AMDGPU] Avoid Using `byval` for `ndrange_t...
Shilei Tian via All-commits
all-commits at lists.llvm.org
Fri Nov 15 12:32:49 PST 2024
Branch: refs/heads/users/shiltian/no-byval-amdgpu
Home: https://github.com/llvm/llvm-project
Commit: c48f66338d05e21f2a60062cf825f4cba445d5d8
https://github.com/llvm/llvm-project/commit/c48f66338d05e21f2a60062cf825f4cba445d5d8
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