[llvm] [NVPTX] Convert calls to indirect when call signature mismatches function signature (PR #107644)

Artem Belevich via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 9 15:04:56 PDT 2024


Artem-B wrote:

Unless we find a good reason to make an extra effort to make these mismatches work (in an undefined way, at that), my preferred choice would be to fail. Debugging such a mismatch in a GPU code leading to subtle errors at runtime will be a rather terrible experience, and I'd rather catch it at compile time.

However, the fact that LLVM does not complain about such mismatch suggests that I may be missing something.

@nikic  -- would you happen to have thoughts/suggestions on this? Do we need to handle mismatches between the function prototype and the call site? Or can we consider them to be an error?

https://github.com/llvm/llvm-project/pull/107644


More information about the llvm-commits mailing list