Re: measure costs of computation on mpf t-variables usenett at
Thu Jul 28 14:38:56 CEST 2005

> > i have the following question. I wanted to measure how much cycles an
> > initialization, multiplication and so on for some special mpf_t
> > variables
> > costs. Paradoxically the first loop needs quantities more cycles
> > than the
> > arithmetical average. For the initialization up to 110000 (in
> > average about
> > 420), for the multiplication up to 5000 (in average about 160).
> > Can anyone explain why this the case?
> > Is there ay better way to get the costs of some computation than mine?
> What's paradoxical about it? This is exactly what I would expect,
> mostly due to cache effects.

Hmm, that was also my first thougt. But clearing the variables after each
loop should result in allocation of the variables of the next loop at a
different memory space, or am I wrong? So faster cache access wouldn't have
any effect on it.

Would the effect be the same, if i won't work all the loops with the same
but with random floats?

Greets, Heinz

5 GB Mailbox, 50 FreeSMS
+++ GMX - die erste Adresse für Mail, Message, More +++

More information about the gmp-discuss mailing list