aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
diff options
context:
space:
mode:
authorJoseph Huber <huberjn@outlook.com>2025-06-02 09:35:16 -0500
committerGitHub <noreply@github.com>2025-06-02 09:35:16 -0500
commit5b8031a7f7e278af5ab9418a3dfa2cad66310278 (patch)
tree872699046c559f93ef8762dcdf4aa665271d819a /llvm/lib/Bitcode/Writer/BitcodeWriter.cpp
parent41e22aa31b1905aa3e9d83c0343a96ec0d5187ec (diff)
downloadllvm-5b8031a7f7e278af5ab9418a3dfa2cad66310278.zip
llvm-5b8031a7f7e278af5ab9418a3dfa2cad66310278.tar.gz
llvm-5b8031a7f7e278af5ab9418a3dfa2cad66310278.tar.bz2
[Offload][AMDGPU] Correctly handle variable implicit argument sizes (#142199)
Summary: The size of the implicit argument struct can vary depending on optimizations, it is not always the size as listed by the full struct. Additionally, the implicit arguments are always aligned on a pointer boundary. This patch updates the handling to use the correctly aligned offset and only initialize the members if they are contained in the reported size. Additionally, we modify the `alloc` and `free` routines to allow `alloc(0)` and `free(nullptr)` as these are mandated by the C standard and allow us to easily handle cases where the user calls a kernel with no arguments.
Diffstat (limited to 'llvm/lib/Bitcode/Writer/BitcodeWriter.cpp')
0 files changed, 0 insertions, 0 deletions