This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [RFC] Update gmp/mpfr/mpc minimum versions
- From: Bernd Edlinger <bernd dot edlinger at hotmail dot de>
- To: Rainer Orth <ro at CeBiTec dot Uni-Bielefeld dot DE>
- Cc: Joseph Myers <joseph at codesourcery dot com>, "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, Richard Biener <rguenther at suse dot de>, "Marc Glisse <marc dot glisse at inria dot fr>; Jakub Jelinek <jakub at redhat dot com>; Jonathan Wakely" <jwakely at redhat dot com>
- Date: Wed, 27 Apr 2016 15:47:31 +0000
- Subject: Re: [RFC] Update gmp/mpfr/mpc minimum versions
- Authentication-results: sourceware.org; auth=none
- Authentication-results: spf=softfail (sender IP is 25.152.2.51) smtp.mailfrom=hotmail.de; CeBiTec.Uni-Bielefeld.DE; dkim=none (message not signed) header.d=none;CeBiTec.Uni-Bielefeld.DE; dmarc=none action=none header.from=hotmail.de;
- References: <AM4PR07MB1571E7BDED31B7C146A0BC4CE4630 at AM4PR07MB1571 dot eurprd07 dot prod dot outlook dot com> <alpine dot DEB dot 2 dot 20 dot 1604262007090 dot 2787 at digraph dot polyomino dot org dot uk> <HE1PR07MB15805C6A09E3DAC3380023BEE4640 at HE1PR07MB1580 dot eurprd07 dot prod dot outlook dot com> <yddmvof83m5 dot fsf at lokon dot CeBiTec dot Uni-Bielefeld dot DE>
Am 27.04.2016 um 17:37 schrieb Rainer Orth:
> Bernd Edlinger <bernd.edlinger@hotmail.de> writes:
>
>> On 26.04.2016 22:14, Joseph Myers wrote:
>>> On Tue, 26 Apr 2016, Bernd Edlinger wrote:
>>>
>>>> Hi,
>>>>
>>>> as we all know, it's high time now to adjust the minimum supported
>>>> gmp/mpfr/mpc versions for gcc-7.
>>>
>>> I think updating the minimum versions (when using previously built
>>> libraries, not in-tree) is only appropriate when it allows some cleanup in
>>> GCC, such as removing conditionals on whether a more recently added
>>> function is available, adding functionality that depends on a newer
>>> interface, or using newer interfaces instead of older ones that are now
>>> deprecated.
>>>
>>> For example, you could justify a move to requiring MPFR 3.0.0 or later
>>> with cleanups to use MPFR_RND* instead of the older GMP_RND*, and
>>> similarly mpfr_rnd_t instead of the older mp_rnd_t and likewise mpfr_exp_t
>>> and mpfr_prec_t in fortran/. You could justify a move to requiring MPC
>>> 1.0.0 (or 1.0.2) by optimizing clog10 using mpc_log10. I don't know what
>>> if any newer GMP interfaces would be beneficial in GCC. And as always in
>>> such cases, it's a good idea to look at e.g. how widespread the newer
>>> versions are in GNU/Linux distributions, which indicates how many people
>>> might be affected by an increase in the version requirement.
>>>
>>
>> Yes I see.
>>
>> I would justify it this way: gmp-6.0.0 is the first version that does
>> not invoke undefined behavior in gmp.h, once we update to gmp-6.0.0
>> we could emit at least a warning in cstddef for this invalid code.
>>
>> Once we have gmp-6.0.0, the earliest mpfr version that compiles at all
>> is mpfr-3.1.1 and the earliest mpc version that compiles at all is
>> mpc-0.9. This would be the supported installed versions.
>>
>> In-tree gmp-6.0.0 does _not_ work for ARM. But gmp-6.1.0 does (with a
>> little quirk). All supported mpfr and mpc versions are working in-tree
>> too, even for the ARM target.
>>
>> When we have at least mpfr-3.1.1, it is straight forward to remove the
>> pre-3.1.0 compatibility code from gcc/fortran/simplify.c for instance.
>>
>> So I would propose this updated patch for gcc-7.
>
> would this version combo (gmp 6.0.0, mpfr 3.1.1, mpc 0.9) also work on
> the active release branches (gcc-5 and gcc-6, gcc-4.9 is on it's way
> out)? Having to install two different sets of the libraries for trunk
> and branch work would be extremely tedious.
>
> Rainer
>
Yes, when they are pre-installed there should be no problem.
Also newer versions than these seem to work.
In-tree only the versions that download_prerequisite picks are
tested and guaranteed to work.