This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH/gfortran] Fix rounding in constant folding
Steve Kargl wrote:
> The newest version of MPFR (which isn't bundled in GMP)
> has a whole boat load of functions that we can use to
> simplify the constant folding (eg., mpfr_nextabove, and
> mpfr_nextbelow, etc.). Eventually, GMP will delete its
> copy of MPFR, perhaps after 4.0 we should consider updating
> the required library version of MPFR.
I agree. The thing that should happen is that someone imports GMP and mpfr
into the gcc tree, so that version dependencies pose no problem.
mpfr 2.0.1 already has mpfr_add_one_ulp and mpfr_sub_one_ulp which should be
sufficient for the purposes of NEAREST. I'll know once my build finishes.
I'll add a comment pointing to the functions you mentioned in any case.
- Tobi