[all-commits] [llvm/llvm-project] 350089: [libc] Fix LLVM_LIBC_FUNCTION on 32-bit x86 Window...

Nico Weber via All-commits all-commits at lists.llvm.org
Sat Aug 1 11:48:42 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 350089d0cb1652e6ff44888f46d6487db5e696e6
      https://github.com/llvm/llvm-project/commit/350089d0cb1652e6ff44888f46d6487db5e696e6
  Author: Nico Weber <thakis at chromium.org>
  Date:   2026-08-01 (Sat, 01 Aug 2026)

  Changed paths:
    M libc/src/__support/common.h

  Log Message:
  -----------
  [libc] Fix LLVM_LIBC_FUNCTION on 32-bit x86 Windows (#213456)

Previously, trying to compile libm with LIBC_COPT_PUBLIC_PACKAGING
defined failed on 32-bit Windows with

    error: alias must point to a defined variable or function

This is because 32-bit Windows adds a leading underscore to __cdecl C
functions, making the alias declaration not find its target symbol name.
The same problem exists on Apple platforms, which as solution don't emit
the alias for the C++ LIBC_NAMESPACE:: symbol.

Do the same on 32-bit Windows as on Apple platforms: Emit only
the underscore-prefixed symbol, not the LIBC_NAMESPACE:: alias.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list