Bug#887169: libc6: recent upgrade to 2.26-3 broke Steam games (Civ5)
On 2018-01-15 14:52, Florian Weimer wrote: > On 01/15/2018 12:22 AM, Aurelien Jarno wrote: > > I don't think it is actually the consensus, only Arch Linux has chosen > > this solution, and building the whole glibc with this option will have > > an impact of the performances for all binaries, not only the broken > > Steam ones. I therefore don't think it's the right way to fix the bug. > > For Fedora, I disabled multiarch support for the i386 builds because it's > not entirely unlikely that there will be similar issues. The issue seems to have been triggered by the switch to GCC 7. We can restore the previous state by fixing the missed-optimization in GCC 7 (already fixed on the trunk). I would believe that similar issues not due to the GCC 7 switch would have been already reported for previous glibc versions. > If we could assume SSE2 support and built the distribution with > -march=x86-64, we would likely have to go the -mstackrealign route. But > this is just an educated guess. Increasing the ISA to -march=x86-64 would probably render the i386 architecture pointless as then people could just use the amd64 architecture instead. -- Aurelien Jarno GPG: 4096R/1DDD8C9B aurel...@aurel32.net http://www.aurel32.net
Bug#887169: libc6: recent upgrade to 2.26-3 broke Steam games (Civ5)
On 01/15/2018 12:22 AM, Aurelien Jarno wrote: I don't think it is actually the consensus, only Arch Linux has chosen this solution, and building the whole glibc with this option will have an impact of the performances for all binaries, not only the broken Steam ones. I therefore don't think it's the right way to fix the bug. For Fedora, I disabled multiarch support for the i386 builds because it's not entirely unlikely that there will be similar issues. If we could assume SSE2 support and built the distribution with -march=x86-64, we would likely have to go the -mstackrealign route. But this is just an educated guess. Thanks, Florian
Bug#887169: libc6: recent upgrade to 2.26-3 broke Steam games (Civ5)
Hello, The GLIBC_TUNABLES solution indeed works. Thanks for the quick response! Best, James On 2018-01-14 03:22 PM, Aurelien Jarno wrote: > clone 887169 -1 > reassign -1 gcc-7 > retitle -1 gcc-7: missed optimization of glibc strspn SSE 4.2 variant > forwarded -1 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81481 > block 887169 by -1 > thanks > > On 2018-01-14 10:35, James Lu wrote: >> Package: libc6 >> Version: 2.26-3 >> Severity: normal >> >> Dear maintainers, >> >> On a recent glibc upgrade on buster/sid (first to 2.26-2 and then >> 2.26-3), one Steam game (Civilization V) consistently segfaults on startup. >> >> Similar issues have been reported in Arch Linux[1], Fedora[2], and >> OpenSUSE[3], where the consensus was that building glibc with > > From what I get about the above reported issues, this bug is caused by: > - the Steam games not following the Linux/x86 ABI wrt stack alignement > - the SSE4.2 version of the strspn function needing to push an SSE > register to the stack when build with GCC 7, due to a missed > optimization. > >> -mstackrealign fixed the issue. (I haven't been able to get such a local >> build working though) > > I don't think it is actually the consensus, only Arch Linux has chosen > this solution, and building the whole glibc with this option will have > an impact of the performances for all binaries, not only the broken > Steam ones. I therefore don't think it's the right way to fix the bug. > > Instead it looks like fixing PR81481 [1] on the GCC 7 side, and then > rebuilding glibc is the way to go. I am therefore cloning this bug to > gcc-7 so that it can happens. > > In the meantime I guess you can run the Steam games by disabling SSE4.2 > optimized function using the glibc tunables. Run the game with the > GLIBC_TUNABLES environment variable defined as follow: > > GLIBC_TUNABLES=glibc.tune.hwcaps=-SSE4_2 > > Aurelien > > [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81481 >
Processed: Re: Bug#887169: libc6: recent upgrade to 2.26-3 broke Steam games (Civ5)
Processing commands for cont...@bugs.debian.org: > clone 887169 -1 Bug #887169 [libc6] libc6: recent upgrade to 2.26-3 broke Steam games (Civ5) Bug 887169 cloned as bug 887327 > reassign -1 gcc-7 Bug #887327 [libc6] libc6: recent upgrade to 2.26-3 broke Steam games (Civ5) Bug reassigned from package 'libc6' to 'gcc-7'. No longer marked as found in versions glibc/2.26-3. Ignoring request to alter fixed versions of bug #887327 to the same values previously set > retitle -1 gcc-7: missed optimization of glibc strspn SSE 4.2 variant Bug #887327 [gcc-7] libc6: recent upgrade to 2.26-3 broke Steam games (Civ5) Changed Bug title to 'gcc-7: missed optimization of glibc strspn SSE 4.2 variant' from 'libc6: recent upgrade to 2.26-3 broke Steam games (Civ5)'. > forwarded -1 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81481 Bug #887327 [gcc-7] gcc-7: missed optimization of glibc strspn SSE 4.2 variant Set Bug forwarded-to-address to 'https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81481'. > block 887169 by -1 Bug #887169 [libc6] libc6: recent upgrade to 2.26-3 broke Steam games (Civ5) 887169 was not blocked by any bugs. 887169 was not blocking any bugs. Added blocking bug(s) of 887169: 887327 > thanks Stopping processing here. Please contact me if you need assistance. -- 887169: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=887169 887327: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=887327 Debian Bug Tracking System Contact ow...@bugs.debian.org with problems
Bug#887169: libc6: recent upgrade to 2.26-3 broke Steam games (Civ5)
clone 887169 -1 reassign -1 gcc-7 retitle -1 gcc-7: missed optimization of glibc strspn SSE 4.2 variant forwarded -1 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81481 block 887169 by -1 thanks On 2018-01-14 10:35, James Lu wrote: > Package: libc6 > Version: 2.26-3 > Severity: normal > > Dear maintainers, > > On a recent glibc upgrade on buster/sid (first to 2.26-2 and then > 2.26-3), one Steam game (Civilization V) consistently segfaults on startup. > > Similar issues have been reported in Arch Linux[1], Fedora[2], and > OpenSUSE[3], where the consensus was that building glibc with From what I get about the above reported issues, this bug is caused by: - the Steam games not following the Linux/x86 ABI wrt stack alignement - the SSE4.2 version of the strspn function needing to push an SSE register to the stack when build with GCC 7, due to a missed optimization. > -mstackrealign fixed the issue. (I haven't been able to get such a local > build working though) I don't think it is actually the consensus, only Arch Linux has chosen this solution, and building the whole glibc with this option will have an impact of the performances for all binaries, not only the broken Steam ones. I therefore don't think it's the right way to fix the bug. Instead it looks like fixing PR81481 [1] on the GCC 7 side, and then rebuilding glibc is the way to go. I am therefore cloning this bug to gcc-7 so that it can happens. In the meantime I guess you can run the Steam games by disabling SSE4.2 optimized function using the glibc tunables. Run the game with the GLIBC_TUNABLES environment variable defined as follow: GLIBC_TUNABLES=glibc.tune.hwcaps=-SSE4_2 Aurelien [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81481 -- Aurelien Jarno GPG: 4096R/1DDD8C9B aurel...@aurel32.net http://www.aurel32.net
Bug#887169: libc6: recent upgrade to 2.26-3 broke Steam games (Civ5)
Package: libc6 Version: 2.26-3 Severity: normal Dear maintainers, On a recent glibc upgrade on buster/sid (first to 2.26-2 and then 2.26-3), one Steam game (Civilization V) consistently segfaults on startup. Similar issues have been reported in Arch Linux[1], Fedora[2], and OpenSUSE[3], where the consensus was that building glibc with -mstackrealign fixed the issue. (I haven't been able to get such a local build working though) [1]: https://bugs.archlinux.org/task/54136?project=0=id=desc=glibc [2]: https://bugzilla.redhat.com/show_bug.cgi?id=1471427 [3]: https://bugzilla.opensuse.org/show_bug.cgi?id=1048861 The gdb traceback is as follows: Thread 14 "Civ5XP" received signal SIGSEGV, Segmentation fault. [Switching to Thread 0xedaffb40 (LWP 30672)] __strspn_sse42 (s=0xedafb148 "# This file is part of PulseAudio.\n", a=0xe696ec2d " \t\n") at ../sysdeps/x86_64/multiarch/strspn-c.c:74 74 ../sysdeps/x86_64/multiarch/strspn-c.c: No such file or directory. (gdb) bt #0 __strspn_sse42 (s=0xedafb148 "# This file is part of PulseAudio.\n", a=0xe696ec2d " \t\n") at ../sysdeps/x86_64/multiarch/strspn-c.c:74 #1 0xe6933896 in parse_line (state=0xedafb128) at pulsecore/conf-parser.c:85 #2 pa_config_parse (filename=0xe6be4510 "/etc/pulse/client.conf", f=0xe6bd89b0, t=0xedafc1b0, proplist=0x0, use_dot_d=true, userdata=0x0) at pulsecore/conf-parser.c:204 #3 0xe69250cb in pa_client_conf_load (c=0xe6bac7c0, load_from_x11=true, load_from_env=true) at pulse/client-conf.c:153 #4 0xe69b10a4 in pa_context_new_with_proplist (mainloop=0xe6bc3bd0, name=0xedafc340 "Civ5XP", p=0x0) at pulse/context.c:171 #5 0xe69b120e in pa_context_new (mainloop=0xe6bc3bd0, name=0xedafc340 "Civ5XP") at pulse/context.c:103 #6 0xf7839f48 in ?? () from ./libopenal.so.1 #7 0xf783a4ab in ?? () from ./libopenal.so.1 #8 0xf783ce06 in ?? () from ./libopenal.so.1 #9 0xf78120a3 in alcOpenDevice () from ./libopenal.so.1 #10 0x09126f34 in YUV12 () #11 0x091264a2 in YUV12 () #12 0x09113bee in check_for_pending_io () #13 0x09114188 in BinkOpen () #14 0x085f7553 in ASL::PlayBinkMovieGL(char const*, float, unsigned int, unsigned int, bool*) () #15 0x0884c26c in PlayMovieState::Begin() () #16 0x086e0fc3 in Civ5App::PlayOpeningMovie() () #17 0x086e1c46 in Civ5App::Init(char const*) () #18 0x0865b3ed in WinMain () #19 0x085f5487 in ?? () #20 0x085d8e3e in ThreadHANDLE::ThreadProc(void*) () #21 0xf7b6b326 in start_thread (arg=0xedaffb40) at pthread_create.c:465 #22 0xf79b42b6 in clone () at ../sysdeps/unix/sysv/linux/i386/clone.S:108 Best, James