Re: glibc regression on alpha with 2.34+

Frank Scheiner <[email protected]> Thu, 15 Dec 2022 10:49:46 +0100
Newsgroups gmane.linux.debian.ports.alpha
Message-ID <[email protected]>
Hi,

On 15.12.22 09:09, John Paul Adrian Glaubitz wrote:
> Hi!
> 
> On 12/14/22 21:44, Frank Scheiner wrote:
>>> I'm attaching the second diff as a patch.
>>
>> I think there's some whitespace difference. I manually applied the
>> rejected stuff, made a `git diff` and comparing that to your attached
>> patch gives:
> 
> Or just use the attached patch file from my previous mail.

Yeah, did that in the end to be sure, but it looks like both are 
incomplete (because both versions gave the following result):

```
root@ds15:/srv/storage/glibc# git status
HEAD detached at glibc-2.34
nothing to commit, working tree clean

root@ds15:/srv/storage/glibc# patch -p1 < ../../bz20305-workaround2.patch
patching file elf/dl-sysdep.c
patching file elf/rtld_static_init.c
patching file sysdeps/generic/ldsodefs.h
patching file sysdeps/unix/sysv/linux/sysconf-pthread_stack_min.h
patching file sysdeps/unix/sysv/linux/sysconf.c

root@ds15:/srv/storage/glibc# cd ../build/glibc-2.34-plus-patch/
root@ds15:/srv/storage/build/glibc-2.34-plus-patch# 
CC="alpha-linux-gnu-gcc-12 -mcpu=ev67 -mtune=ev67 " 
CXX="alpha-linux-gnu-g++-12 -mcpu=ev67 -mtune=ev67 " 
MIG="alpha-linux-gnu-mig" ../../glibc/configure 
--host=alphaev67-linux-gnu --disable-werror --prefix=/usr 
--disable-sanity-checks
[...]

root@ds15:/srv/storage/build/glibc-2.34-plus-patch# time make
[...]
alpha-linux-gnu-gcc-12 -mcpu=ev67 -mtune=ev67 
../sysdeps/unix/sysv/linux/alpha/sysconf.c -c -std=gnu11 -fgnu89-inline 
-g -O2 -Wall -Wwrite-strings -Wundef -fmerge-all-constants 
-frounding-math -fno-stack-protector -fno-common -Wstrict-prototypes 
-Wold-style-definition -fmath-errno -mlong-double-128 -mieee 
-mfp-rounding-mode=d   -fexceptions 
-DGETCONF_DIR='"/usr/libexec/getconf"'  -ftls-model=initial-exec 
-I../include -I/srv/storage/build/glibc-2.34-plus-patch/posix 
-I/srv/storage/build/glibc-2.34-plus-patch 
-I../sysdeps/unix/sysv/linux/alpha/alphaev67/fpu 
-I../sysdeps/alpha/alphaev67/fpu 
-I../sysdeps/unix/sysv/linux/alpha/alphaev67 
-I../sysdeps/unix/sysv/linux/alpha/fpu  -I../sysdeps/alpha/fpu 
-I../sysdeps/unix/sysv/linux/alpha  -I../sysdeps/alpha/nptl 
-I../sysdeps/unix/sysv/linux/wordsize-64 
-I../sysdeps/ieee754/ldbl-64-128  -I../sysdeps/ieee754/ldbl-opt 
-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/alpha 
-I../sysdeps/unix  -I../sysdeps/posix  -I../sysdeps/alpha/alphaev67 
-I../sysdeps/alpha/alphaev6  -I../sysdeps/alpha/alphaev5 
-I../sysdeps/alpha  -I../sysdeps/wordsize-64 
-I../sysdeps/ieee754/ldbl-128  -I../sysdeps/ieee754/dbl-64 
-I../sysdeps/ieee754/flt-32  -I../sysdeps/ieee754  -I../sysdeps/generic 
-I.. -I../libio -I.  -D_LIBC_REENTRANT -include 
/srv/storage/build/glibc-2.34-plus-patch/libc-modules.h 
-DMODULE_NAME=libc -include ../include/libc-symbols.h 
-DTOP_NAMESPACE=glibc -o 
/srv/storage/build/glibc-2.34-plus-patch/posix/sysconf.o -MD -MP -MF 
/srv/storage/build/glibc-2.34-plus-patch/posix/sysconf.o.dt -MT 
/srv/storage/build/glibc-2.34-plus-patch/posix/sysconf.o
In file included from ../sysdeps/alpha/ldsodefs.h:40,
                  from ../sysdeps/gnu/ldsodefs.h:46,
                  from ../sysdeps/unix/sysv/linux/ldsodefs.h:25,
                  from ../sysdeps/unix/sysv/linux/sysconf.c:29,
                  from ../sysdeps/unix/sysv/linux/alpha/sysconf.c:127:
../sysdeps/unix/sysv/linux/sysconf-sigstksz.h: In function 
‘sysconf_sigstksz’:
../sysdeps/generic/ldsodefs.h:512:21: error: ‘_dl_minsigstacksize’ 
undeclared (first use in this function); did you mean ‘minsigstacksize’?
   512 | # define GLRO(name) _##name
       |                     ^
../sysdeps/unix/sysv/linux/sysconf-sigstksz.h:24:30: note: in expansion 
of macro ‘GLRO’
    24 |   long int minsigstacksize = GLRO(dl_minsigstacksize);
       |                              ^~~~
../sysdeps/generic/ldsodefs.h:512:21: note: each undeclared identifier 
is reported only once for each function it appears in
   512 | # define GLRO(name) _##name
       |                     ^
../sysdeps/unix/sysv/linux/sysconf-sigstksz.h:24:30: note: in expansion 
of macro ‘GLRO’
    24 |   long int minsigstacksize = GLRO(dl_minsigstacksize);
       |                              ^~~~
In file included from ../sysdeps/unix/sysv/linux/sysconf.c:30:
../sysdeps/unix/sysv/linux/sysconf-sigstksz.h: At top level:
../sysdeps/unix/sysv/linux/sysconf-sigstksz.h:22:1: warning: 
‘sysconf_sigstksz’ defined but not used [-Wunused-function]
    22 | sysconf_sigstksz (void)
       | ^~~~~~~~~~~~~~~~
make[2]: *** [/srv/storage/build/glibc-2.34-plus-patch/sysd-rules:179: 
/srv/storage/build/glibc-2.34-plus-patch/posix/sysconf.o] Error 1
make[2]: Leaving directory '/srv/storage/glibc/posix'
make[1]: *** [Makefile:478: posix/subdir_lib] Error 2
make[1]: Leaving directory '/srv/storage/glibc'
make: *** [Makefile:9: all] Error 2

real	32m23.084s
user	23m7.861s
sys	5m13.960s
```

Maybe adding [1] might help, but the patch actually removes it.

[1]: 
https://github.com/bminor/glibc/commit/6c57d320484988e87e446e2e60ce42816bf51d53#diff-a0f6ca39e050317adcf156062ab073beb500c3c9d75b4d9adad7a8a08f42e5f3

Cheers,
Frank