gmp_printf vs mpz_get_string

Torbjorn Granlund tg at gmplib.org
Mon Oct 15 22:23:50 CEST 2012


Joakim Carselind <joacar at kth.se> writes:

  Is calling mpz_get_string a significant overhead vs calling gmp_printf()?

I am not aware of any function called mpz_get_string.  Perhaps you mean
mpz_get_str?

Is your question whether gmp_printf is faster than mpz_get_str and then
significantly so?

Since gmp_printf calls mpz_get_str for its integer output, the former
function will hardly be faster than the latter function.

-- 
Torbjörn


More information about the gmp-discuss mailing list