From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 33DC4385800F; Mon, 24 Jan 2022 10:18:42 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 33DC4385800F From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug bootstrap/104170] [12 Regression] Failed to bootstrap by r12-6807 Date: Mon, 24 Jan 2022 10:18:42 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: bootstrap X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: FIXED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 12.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 24 Jan 2022 10:18:42 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D104170 --- Comment #4 from CVS Commits --- The master branch has been updated by Jakub Jelinek : https://gcc.gnu.org/g:2c31a8be4a5db11a0a0e97c366dded6362421086 commit r12-6838-g2c31a8be4a5db11a0a0e97c366dded6362421086 Author: Jakub Jelinek Date: Mon Jan 24 11:13:39 2022 +0100 properly disable -fsplit-stack on non-glibc targets [PR104170] On Sat, Jan 22, 2022 at 10:32:21AM +0100, Martin Li=C3=85=C2=A1ka wrote: > I've just noticed the patch broke a few cross compilers: > > s390x-ibm-tpf: > > /home/marxin/buildworker/zen2-cross-compilers/build/gcc/common/config/s390/= s390-common.cc: In function =C3=A2bool s390_supports_split_stack(bool, gcc_options*)=C3=A2: > /home/marxin/buildworker/zen2-cross-compilers/build/gcc/common/config/s390/= s390-common.cc:126:13: error: =C3=A2struct gcc_options=C3=A2 has no member named =C3=A2x_linux_lib= c=C3=A2 > 126 | if (opts->x_linux_libc =3D=3D LIBC_GLIBC) > | ^~~~~~~~~~~~ > > i686-kopensolaris-gnu, i686-symbolics-gnu > > /home/marxin/buildworker/zen2-cross-compilers/build/gcc/common/config/i386/= i386-common.cc: In function =C3=A2bool ix86_supports_split_stack(bool, gcc_options*)=C3=A2: > /home/marxin/buildworker/zen2-cross-compilers/build/gcc/common/config/i386/= i386-common.cc:1721:13: error: =C3=A2struct gcc_options=C3=A2 has no member named =C3=A2x_linux_lib= c=C3=A2 > 1721 | if (opts->x_linux_libc !=3D LIBC_GLIBC) > | ^~~~~~~~~~~~ > make[1]: *** [Makefile:2418: i386-common.o] Error 1 > > Can you please take a look? Btw. do you have a bugzilla account? I bet instead of opts->x_linux_libc !=3D LIBC_GLIBC it needs to use #ifdef OPTION_GLIBC if (!OPTION_GLIBC) #endif or so. I think the first committed patch actually used that but used it in #if directive, which is wrong because it is something that needs to be evaluated at runtime. That doesn't work well either, because the *supports_split_stack hooks have opts argument and OPTION_GLIBC doesn't take that. So, here is a patch that introduces OPTION_*_P macros that take opts as an argument and redefines OPTION_* using those (similarly to how the option scripts create TARGET_*_P and TARGET_* macros). 2022-01-24 Jakub Jelinek PR bootstrap/104170 * config/linux.h (OPTION_GLIBC_P, OPTION_UCLIBC_P, OPTION_BIONIC_P, OPTION_MUSL_P): Define. (OPTION_GLIBC, OPTION_UCLIBC, OPTION_BIONIC, OPTION_MUSL): Rede= fine using OPTION_*_P macros. * config/alpha/linux.h (OPTION_GLIBC_P, OPTION_UCLIBC_P, OPTION_BIONIC_P, OPTION_MUSL_P): Define. (OPTION_GLIBC, OPTION_UCLIBC, OPTION_BIONIC, OPTION_MUSL): Rede= fine using OPTION_*_P macros. * config/rs6000/linux.h (OPTION_GLIBC_P, OPTION_UCLIBC_P, OPTION_BIONIC_P, OPTION_MUSL_P): Define. (OPTION_GLIBC, OPTION_UCLIBC, OPTION_BIONIC, OPTION_MUSL): Rede= fine using OPTION_*_P macros. * config/rs6000/linux64.h (OPTION_GLIBC_P, OPTION_UCLIBC_P, OPTION_BIONIC_P, OPTION_MUSL_P): Define. (OPTION_GLIBC, OPTION_UCLIBC, OPTION_BIONIC, OPTION_MUSL): Rede= fine using OPTION_*_P macros. * config/fuchsia.h (OPTION_MUSL_P): Redefine. * config/glibc-stdint.h (OPTION_MUSL_P): Define if not defined. * common/config/s390/s390-common.cc (s390_supports_split_stack): Re-add ATTRIBUTE_UNUSED to opts parameter. If OPTION_GLIBC_P is defin= ed, use OPTION_GLIBC_P (opts) as condition, otherwise assume if (false). * common/config/i386/i386-common.cc (ix86_supports_split_stack)= : If OPTION_GLIBC_P is defined use !OPTION_GLIBC_P (opts) as conditi= on, otherwise assume if (true).=