two questions on GMP & C float

Vincent Lefevre vincent at vinc17.org
Sat May 16 19:16:11 CEST 2009


On 2009-05-16 17:53:00 +0200, Marc Glisse wrote:
> Compared to (mpz,int) (and mpf), I think mpfr has alloc==size (this could 
> be changed in a compatible way (except for a couple macros that expose 
> too much internals), or allocated storage could be truncated (if  
> mpfr_free_func ignores size), so I may be mistaken), which makes a lot of 
> sense for fixed precision arithmetic, but may be a bit less convenient  
> here (I don't really know, it may not matter so much).

What do you mean by alloc==size?

Note that currently, when you reduce the precision of a mpfr_t,
the allocated size remains the same (see the MPFR source for more
information).

-- 
Vincent Lefèvre <vincent at vinc17.org> - Web: <http://www.vinc17.org/>
100% accessible validated (X)HTML - Blog: <http://www.vinc17.org/blog/>
Work: CR INRIA - computer arithmetic / Arenaire project (LIP, ENS-Lyon)


More information about the gmp-discuss mailing list