From: Marius Hillenbrand <mhillen@linux.ibm.com>
To: musl@lists.openwall.com
Subject: Re: [musl] [PATCH] s390x: derive float_t from compiler or default to float
Date: Thu, 3 Dec 2020 17:53:52 +0100 [thread overview]
Message-ID: <108407b0-24ac-d3d3-43c1-f394ba6bbebe@linux.ibm.com> (raw)
In-Reply-To: <20201202191306.GX534@brightrain.aerifal.cx>
On 12/2/20 8:13 PM, Rich Felker wrote:
> On Wed, Dec 02, 2020 at 06:09:44PM +0100, Marius Hillenbrand wrote:
>> On 12/2/20 5:01 PM, Rich Felker wrote:
>>> On Wed, Dec 02, 2020 at 09:25:04AM -0500, Rich Felker wrote:
[...]
>>> I'm looking at
>>> https://gcc.gnu.org/pipermail/gcc-patches/2020-November/560225.html
>>> which seems to be what you're talking about, and don't understand how
>>> it's intended to work. It looks like it's running a test for target
>>> behavior on the host compiler (there is no target compiler at the
>>> point this test is run). Looking again, I guess that's why it's under
>>> a condition for build==host==target.
>>
>> Right, that's the patch. The check only applies to a "native build",
>> with the assumption that the build environment is the same as the
>> intended target environment.
>>
>>> What happens when cross
>>> compiling? Do you get the old behavior unless manually setting
>>> --disable-s390-excess-float-precision?
>>
>> When cross compiling, we get the new behavior (the setting starts at
>> "auto", which is never resolved to yes or no; so the AC_DEFINE is left out).
>>
>> In any case, manually setting
>> --enable/disable-s390-excess-float-precision takes precedence.
>
> FWIW this means building GCC 11 for any older version of glibc or musl
> will give a broken configuration unless you pass
> --disable-s390-excess-float-precision to configure. I'm not sure if
> anything should be done about that; at least I might want to handle it
> in mcm...
I will look into handling cross compiles in a more differentiating way...
>
> In any case this probably means I should include your patch in this
> release cycle so at least current version builds right.
>
> BTW is there a -m option to override at runtime in order to test both
> behaviors, so you don't have to build a new GCC from scratch to do it?
Yes, in the current GCC, -fexcess-precision=standard or fast switches
between the two behaviors (i.e., both __FLT_EVAL_METHOD__ and emitted
code; "fast" corresponds to the "new" behavior).
Marius
--
Marius Hillenbrand
Linux on Z development
IBM Deutschland Research & Development GmbH
Vors. des Aufsichtsrats: Gregor Pillen / Geschäftsführung: Dirk Wittkopp
Sitz der Gesellschaft: Böblingen / Registergericht: Amtsgericht
Stuttgart, HRB 243294
next prev parent reply other threads:[~2020-12-03 16:54 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-01 14:36 Marius Hillenbrand
2020-12-01 20:50 ` Rich Felker
2020-12-02 10:44 ` Marius Hillenbrand
2020-12-02 14:25 ` Rich Felker
2020-12-02 16:01 ` Rich Felker
2020-12-02 17:09 ` Marius Hillenbrand
2020-12-02 19:13 ` Rich Felker
2020-12-03 16:53 ` Marius Hillenbrand [this message]
2020-12-03 19:06 ` Rich Felker
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=108407b0-24ac-d3d3-43c1-f394ba6bbebe@linux.ibm.com \
--to=mhillen@linux.ibm.com \
--cc=musl@lists.openwall.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/musl/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).