[llvm] Revert "[NVPTX] Fixup and test ExpandVariadics (#195709)" (PR #199235)
Alex MacLean via llvm-commits
llvm-commits at lists.llvm.org
Fri May 22 10:21:22 PDT 2026
AlexMaclean wrote:
> Were you able to reproduce this? This might be caused by the function call ABI (the tests compile w/o LTO), or just the address space gets dropped somewhere, I didn't look too deeply into it.
Yes, I was able to reproduce. The problem is that clang does not use the LLVM `va_arg` instruction to load var-args but instead just emits the align then load expansion itself. The clang expansion expects the vaarg cursor to be a generic pointer while the NVPTX backend expansion of `va_arg` expects local. I was aligning this passes behavior with the NVPTX expansion and didn't think about clang. I'll instead follow up with a change updating NVPTX so everywhere agrees on using a generic ptr.
https://github.com/llvm/llvm-project/pull/199235
More information about the llvm-commits
mailing list