Interresting; as far as I can see, the only place mappings are used in the Gmp module, is in _sprintf(). My guess is that the leaked mapping is created by the compiler, and probably is used for symbol lookup cacheing.
/ Henrik Grubbström (Lysator)
Previous text:
2002-09-30 14:23: Subject: Gz testsuite memory usage
Ah-ha. Each time the compiler compiles an expression containing a literal Gmp.mpz creation, it leaks one mapping:
Pike v7.3 release 56 running Hilfe v3.5 (Incremental Pike Frontend)
gc(); _memory_usage()->num_mappings;
(1) Result: 3 (2) Result: 71
for(int i=0; i<1000; i++) compile_string("mixed x = Gmp.mpz(100);");
Ok.
gc(); _memory_usage()->num_mappings;
(3) Result: 0 (4) Result: 1071
/ Marcus Comstedt (ACROSS) (Hail Ilpalazzo!)