[libc-commits] [libc] [libc] Remove the optional arguments for NVPTX constructors (PR #69536)

Joseph Huber via libc-commits libc-commits at lists.llvm.org
Mon Oct 23 09:52:01 PDT 2023


jhuber6 wrote:

> Supporting the extended form doesn't seem fundamentally important. It's not accessible without the attribute(constructor) syntax which is itself a compiler extension. It should have a sema check - looks like that's the above wip.
>

Yes, that was Aaron's work which shouldn't affect too much.
> I'd be happy to accept this if you applied the same simplification to amdgpu and fix the typos in the commit message. We won't have users in the wild that depend on the extended constructor syntax (yet), and we can leave an issue around for either getting nvidia to improve their tooling or implementing a workaround (e.g. we could stash the arguments in global state and retrieve them)

AMDGPU doesn't need to worry about this, it can call either form in a similar manner to calling `main` with and without arguments.

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


More information about the libc-commits mailing list