[Bug math/33735] New: glibc-2.43 fails to build, clang-21, i686: ../sysdeps/x86/fpu/e_sqrtf128.c:43:3: error: invalid use of a cast in an inline asm context requiring an lvalue [-Winvalid-gnu-asm-cast]
dilfridge at gentoo dot org
sourceware-bugzilla@sourceware.org
Sun Dec 21 18:01:05 GMT 2025
https://sourceware.org/bugzilla/show_bug.cgi?id=33735
Bug ID: 33735
Summary: glibc-2.43 fails to build, clang-21, i686:
../sysdeps/x86/fpu/e_sqrtf128.c:43:3: error: invalid
use of a cast in an inline asm context requiring an
lvalue [-Winvalid-gnu-asm-cast]
Product: glibc
Version: 2.41
Status: NEW
Severity: normal
Priority: P2
Component: math
Assignee: unassigned at sourceware dot org
Reporter: dilfridge at gentoo dot org
Target Milestone: ---
Build with Gentoo portage, glibc-9999
MAKEOPTS="-j1" CC=clang CXX=clang++ TEST_CC=gcc TEST_CXX=g++ ebuild
glibc-9999.ebuild clean test
clang version 21.1.8
Target: i686-pc-linux-gnu
master at 0b8a996f44b5f4c02991f02cd12bf05b17db4576
clang -O2 -march=i686 -pipe -Wno-unused-command-line-argument -Wl,-O1
-Wl,--as-needed -Wl,-z,pack-relative-relocs
../sysdeps/ieee754/float128/e_sinhf128.c -c -std=gnu11 -fgnu89-inline -O2
-march=i686 -pipe -Wno-unused-command-line-argument -Wall -Wwrite-strings
-Wundef -Wimplicit-fallthrough -fmerge-all-constants -frounding-math
-ftrapping-math -fstack-protector-strong -fno-common -U_FORTIFY_SOURCE
-D_FORTIFY_SOURCE=3 -Wstrict-prototypes -Wold-style-definition
-fno-math-errno -fPIE -I../include
-I/var/tmp/portage/sys-libs/glibc-9999/work/build-x86-i686-pc-linux-gnu-nptl/math
-I/var/tmp/portage/sys-libs/glibc-9999/work/build-x86-i686-pc-linux-gnu-nptl
-I../sysdeps/unix/sysv/linux/i386/i686 -I../sysdeps/i386/i686/nptl
-I../sysdeps/unix/sysv/linux/i386 -I../sysdeps/unix/sysv/linux/x86/include
-I../sysdeps/unix/sysv/linux/x86 -I../sysdeps/x86/nptl -I../sysdeps/i386/nptl
-I../sysdeps/unix/sysv/linux/include -I../sysdeps/unix/sysv/linux
-I../sysdeps/nptl -I../sysdeps/pthread -I../sysdeps/gnu
-I../sysdeps/unix/inet -I../sysdeps/unix/sysv -I../sysdeps/unix/i386
-I../sysdeps/unix -I../sysdeps/posix -I../sysdeps/i386/i686/fpu/multiarch
-I../sysdeps/i386/i686/fpu -I../sysdeps/i386/i686/multiarch
-I../sysdeps/i386/i686 -I../sysdeps/i386/fpu -I../sysdeps/x86/fpu
-I../sysdeps/i386 -I../sysdeps/x86/include -I../sysdeps/x86
-I../sysdeps/wordsize-32 -I../sysdeps/ieee754/float128
-I../sysdeps/ieee754/ldbl-96/include -I../sysdeps/ieee754/ldbl-96
-I../sysdeps/ieee754/dbl-64 -I../sysdeps/ieee754/flt-32 -I../sysdeps/ieee754
-I../sysdeps/generic -I.. -I../libio -I. -nostdinc -isystem
/usr/lib/llvm/21/bin/../../../../lib/clang/21/include -isystem /usr/include
-D_LIBC_REENTRANT -include
/var/tmp/portage/sys-libs/glibc-9999/work/build-x86-i686-pc-linux-gnu-nptl/libc-modules.h
-DMODULE_NAME=libm -include ../include/libc-symbols.h -DPIC
-DTOP_NAMESPACE=glibc -I../soft-fp -o
/var/tmp/portage/sys-libs/glibc-9999/work/build-x86-i686-pc-linux-gnu-nptl/math/e_sinhf128.o
-MD -MP -MF
/var/tmp/portage/sys-libs/glibc-9999/work/build-x86-i686-pc-linux-gnu-nptl/math/e_sinhf128.o.dt
-MT
/var/tmp/portage/sys-libs/glibc-9999/work/build-x86-i686-pc-linux-gnu-nptl/math/e_sinhf128.o
clang -O2 -march=i686 -pipe -Wno-unused-command-line-argument -Wl,-O1
-Wl,--as-needed -Wl,-z,pack-relative-relocs ../sysdeps/x86/fpu/e_sqrtf128.c -c
-std=gnu11 -fgnu89-inline -O2 -march=i686 -pipe
-Wno-unused-command-line-argument -Wall -Wwrite-strings -Wundef
-Wimplicit-fallthrough -fmerge-all-constants -frounding-math -ftrapping-math
-fstack-protector-strong -fno-common -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=3
-Wstrict-prototypes -Wold-style-definition -fno-math-errno -fPIE
-I../include
-I/var/tmp/portage/sys-libs/glibc-9999/work/build-x86-i686-pc-linux-gnu-nptl/math
-I/var/tmp/portage/sys-libs/glibc-9999/work/build-x86-i686-pc-linux-gnu-nptl
-I../sysdeps/unix/sysv/linux/i386/i686 -I../sysdeps/i386/i686/nptl
-I../sysdeps/unix/sysv/linux/i386 -I../sysdeps/unix/sysv/linux/x86/include
-I../sysdeps/unix/sysv/linux/x86 -I../sysdeps/x86/nptl -I../sysdeps/i386/nptl
-I../sysdeps/unix/sysv/linux/include -I../sysdeps/unix/sysv/linux
-I../sysdeps/nptl -I../sysdeps/pthread -I../sysdeps/gnu
-I../sysdeps/unix/inet -I../sysdeps/unix/sysv -I../sysdeps/unix/i386
-I../sysdeps/unix -I../sysdeps/posix -I../sysdeps/i386/i686/fpu/multiarch
-I../sysdeps/i386/i686/fpu -I../sysdeps/i386/i686/multiarch
-I../sysdeps/i386/i686 -I../sysdeps/i386/fpu -I../sysdeps/x86/fpu
-I../sysdeps/i386 -I../sysdeps/x86/include -I../sysdeps/x86
-I../sysdeps/wordsize-32 -I../sysdeps/ieee754/float128
-I../sysdeps/ieee754/ldbl-96/include -I../sysdeps/ieee754/ldbl-96
-I../sysdeps/ieee754/dbl-64 -I../sysdeps/ieee754/flt-32 -I../sysdeps/ieee754
-I../sysdeps/generic -I.. -I../libio -I. -nostdinc -isystem
/usr/lib/llvm/21/bin/../../../../lib/clang/21/include -isystem /usr/include
-D_LIBC_REENTRANT -include
/var/tmp/portage/sys-libs/glibc-9999/work/build-x86-i686-pc-linux-gnu-nptl/libc-modules.h
-DMODULE_NAME=libm -include ../include/libc-symbols.h -DPIC
-DTOP_NAMESPACE=glibc -I../soft-fp -o
/var/tmp/portage/sys-libs/glibc-9999/work/build-x86-i686-pc-linux-gnu-nptl/math/e_sqrtf128.o
-MD -MP -MF
/var/tmp/portage/sys-libs/glibc-9999/work/build-x86-i686-pc-linux-gnu-nptl/math/e_sqrtf128.o.dt
-MT
/var/tmp/portage/sys-libs/glibc-9999/work/build-x86-i686-pc-linux-gnu-nptl/math/e_sqrtf128.o
../sysdeps/x86/fpu/e_sqrtf128.c:43:3: error: invalid use of a cast in an inline
asm context requiring an lvalue [-Winvalid-gnu-asm-cast]
43 | FP_SQRT_Q (R, A);
| ^~~~~~~~~~~~~~~~
../soft-fp/quad.h:180:27: note: expanded from macro 'FP_SQRT_Q'
180 | # define FP_SQRT_Q(R, X) _FP_SQRT (Q, 4, R, X)
| ^~~~~~~~~~~~~~~~~~~~~
../soft-fp/op-common.h:1437:4: note: expanded from macro '_FP_SQRT'
1437 | _FP_SQRT_MEAT_##wc (R, _FP_SQRT_S, _FP_SQRT_T, X,
\
|
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1438 | _FP_SQRT_q);
\
| ~~~~~~~~~~~
<scratch space>:293:1: note: expanded from here
293 | _FP_SQRT_MEAT_4
| ^
note: (skipping 1 expansions in backtrace; use -fmacro-backtrace-limit=0 to see
all)
<scratch space>:363:1: note: expanded from here
363 | A_f
| ^
../soft-fp/op-4.h:747:24: note: expanded from macro '__FP_FRAC_DEC_3'
747 | __FP_FRAC_SUB_3 (x2, x1, x0, __FP_FRAC_DEC_3_t2, \
| ~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
748 | __FP_FRAC_DEC_3_t1, __FP_FRAC_DEC_3_t0, \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
749 | y2, y1, y0); \
| ~~~~~~~~~~~
../sysdeps/x86/fpu/sfp-machine.h:119:24: note: expanded from macro
'__FP_FRAC_SUB_3'
119 | : "=r" ((USItype) (r2)), \
| ~~~~~~~~~~~^~~
../sysdeps/x86/fpu/e_sqrtf128.c:43:3: error: invalid use of a cast in an inline
asm context requiring an lvalue [-Winvalid-gnu-asm-cast]
43 | FP_SQRT_Q (R, A);
| ^~~~~~~~~~~~~~~~
../soft-fp/quad.h:180:27: note: expanded from macro 'FP_SQRT_Q'
180 | # define FP_SQRT_Q(R, X) _FP_SQRT (Q, 4, R, X)
| ^~~~~~~~~~~~~~~~~~~~~
../soft-fp/op-common.h:1437:4: note: expanded from macro '_FP_SQRT'
1437 | _FP_SQRT_MEAT_##wc (R, _FP_SQRT_S, _FP_SQRT_T, X,
\
|
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1438 | _FP_SQRT_q);
\
| ~~~~~~~~~~~
<scratch space>:293:1: note: expanded from here
293 | _FP_SQRT_MEAT_4
| ^
note: (skipping 1 expansions in backtrace; use -fmacro-backtrace-limit=0 to see
all)
<scratch space>:364:1: note: expanded from here
364 | A_f
| ^
../soft-fp/op-4.h:747:28: note: expanded from macro '__FP_FRAC_DEC_3'
747 | __FP_FRAC_SUB_3 (x2, x1, x0, __FP_FRAC_DEC_3_t2, \
| ~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
748 | __FP_FRAC_DEC_3_t1, __FP_FRAC_DEC_3_t0, \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
749 | y2, y1, y0); \
| ~~~~~~~~~~~
../sysdeps/x86/fpu/sfp-machine.h:120:25: note: expanded from macro
'__FP_FRAC_SUB_3'
120 | "=&r" ((USItype) (r1)), \
| ~~~~~~~~~~~^~~
../sysdeps/x86/fpu/e_sqrtf128.c:43:3: error: invalid use of a cast in an inline
asm context requiring an lvalue [-Winvalid-gnu-asm-cast]
43 | FP_SQRT_Q (R, A);
| ^~~~~~~~~~~~~~~~
...
--
You are receiving this mail because:
You are on the CC list for the bug.
More information about the Glibc-bugs
mailing list