[libc-commits] [libc] [libc] Provide empty weak implementation of baremetal OSUtil (PR #86916)

Nick Desaulniers via libc-commits libc-commits at lists.llvm.org
Thu Mar 28 08:48:09 PDT 2024


nickdesaulniers wrote:

> I'm undecided whether this is desirable or not. On one hand it makes it easier to drop in LLVM libc without any changes to the existing codebase. On the other hand, we shouldn't be silently ignoring errors and want users to implement these functions whenever possible.

I think it would be better to retain the existing behavior of explicit linkage failure, but we should instead write docs about what minimal runtime elements users MUST implement to use llvm-libc on baremetal.

https://libc.llvm.org/ has a tab "libc for GPUs". Right under it should be "libc for baremetal" which should list what functions need to be provided, and what their semantics need to be.

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


More information about the libc-commits mailing list