From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id B1B743858C20; Mon, 7 Mar 2022 11:07:44 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B1B743858C20 From: "adhemerval.zanella at linaro dot org" To: glibc-bugs@sourceware.org Subject: [Bug ports/28872] Building glibc for MIPSel single float targets Date: Mon, 07 Mar 2022 11:07:44 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: ports X-Bugzilla-Version: 2.30 X-Bugzilla-Keywords: X-Bugzilla-Severity: critical X-Bugzilla-Who: adhemerval.zanella at linaro dot org X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: INVALID X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- 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://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: glibc-bugs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Glibc-bugs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 07 Mar 2022 11:07:44 -0000 https://sourceware.org/bugzilla/show_bug.cgi?id=3D28872 --- Comment #21 from Adhemerval Zanella --- (In reply to Den from comment #20) > (In reply to Adhemerval Zanella from comment #19) > > sysdeps/mips/__longjmp.c > > +# if __mips_fpr =3D=3D 0 || __mips_fpr =3D=3D 64 > > +# define LDFPR "ldc1 " > > +# elif __mips_fpr =3D=3D 32 > > +# define LDFPR "lwc1 " > > +# else > > +# define LDFPR "l.d " > > +# endif > > + asm volatile (LDFPR "$f20, %0" : : "m" (env[0].__fpregs[0])); > > ... > Those LDFPR macroses inside "asm volatile" are not replaced with their lo= gic > definition. That will not do the trick for the .c files, so they can not = be > compiled (as the compiler "thinks" that it is ldfpr opcode). The trick mi= ght > be working with .s files. What do you mean 'replaced with their logic definition' here? For '__mips_f= pr =3D=3D 32' is lwc1 used to restore the floating-point state, which afaiu th= is is the expected intructions to load the for machines which does not contain do= uble precision. >=20 > The bad thing for me is that I obtained that currently there is no a > suitable toolchain with the newest binutils and gcc to build a stable > working cross-compiler for either r6000 with single-float (when using dou= ble > it is OK) or r5900 - that kind of the cross-compiler generates malfunctio= ns > somewhere... Can't you use the expected compiler-flags (-O2 -mabi=3D32 -mfp32 -msingle-f= loat -mhard-float) along with a recent gcc/binutils? > So, I can not check with a test whenever your patch, your suppose about > saving/restoring fp state to/from 32bit registers just by using swc1/lwc1 > "intrusions" in the current ABI realization, is correct or wrong. Because= I > have nothing stable to be sure in, to compare with. --=20 You are receiving this mail because: You are on the CC list for the bug.=