https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115796

            Bug ID: 115796
           Summary: build failure since double_u -> __double_u change
           Product: gcc
           Version: 15.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: prlw1 at cam dot ac.uk
  Target Milestone: ---

Since

commit 3a873c0a7bc8183de95a6103b507101a25eed413 (HEAD)
Author: liuhongt <hongtao....@intel.com>
Date:   Thu May 30 14:15:48 2024 +0800

    Rename double_u with __double_u to avoid pulluting the namespace.

    gcc/ChangeLog:

            * config/i386/emmintrin.h (__double_u): Rename from double_u.
            (_mm_load_sd): Replace double_u with __double_u.
            (_mm_store_sd): Ditto.
            (_mm_loadh_pd): Ditto.
            (_mm_loadl_pd): Ditto.
            * config/i386/xmmintrin.h (__float_u): Rename from float_u.
            (_mm_load_ss): Ditto.
            (_mm_store_ss): Ditto.

I have a build failure on NetBSD as the namespace pollution avoidance causes
a direct hit with the system /usr/include/math.h

Given that this causes pain, but doesn't obviously cause gain, could it be
reverted? (or is there some gain that I am missing?)


=======================================================================

In file included from /usr/src/local/gcc/obj/gcc/include/emmintrin.h:31,
                 from
/usr/src/local/gcc/obj/x86_64-unknown-netbsd10.99/libstdc++-v3/include/ext/random:45,
                 from
/usr/src/local/gcc/libstdc++-v3/include/precompiled/extc++.h:65:
/usr/src/local/gcc/obj/gcc/include/xmmintrin.h:75:15: error: conflicting
declaration 'typedef float __float_u'
   75 | typedef float __float_u __attribute__ ((__may_alias__, __aligned__
(1)));
      |               ^~~~~~~~~
In file included from
/usr/src/local/gcc/obj/x86_64-unknown-netbsd10.99/libstdc++-v3/include/cmath:47,
                 from
/usr/src/local/gcc/obj/x86_64-unknown-netbsd10.99/libstdc++-v3/include/x86_64-unknown-netbsd10.99/bits/stdc++.h:114,
                 from
/usr/src/local/gcc/libstdc++-v3/include/precompiled/extc++.h:32:
/usr/src/local/gcc/obj/gcc/include-fixed/math.h:49:7: note: previous
declaration as 'union __float_u'
   49 | union __float_u {

Reply via email to