On Sun, Jan 08, 2006 at 07:51:57PM +0100, Lars Gullik Bjønnes wrote:
> Martin Vermeer <[EMAIL PROTECTED]> writes:
> 
> | On Sun, Jan 08, 2006 at 03:30:18AM +0100, Lars Gullik Bjønnes wrote:
> | > Martin Vermeer <[EMAIL PROTECTED]> writes:
> | > 
> | > | Attached the IMHO "current best" version of this patch, which was held
> | > | up by a discussion about the best way to find the pit value of a given
> | > | paragraph (loop, linear computation for <vector>, or some std::find
> | > | thing). This proposal doesn't assume <vector>.
> | > 
> | > Do you have any timing test without the patch?
> | 
> | No... but do you think we need, given the time consumption in the whole
> | routine is minimal?
> 
> If it considred for 1.4.0, yes.

OK, here are my results.

(1) User Guide with the patch, inserting 10 rows of a's close to the end.
89391 calls, 0.36 s, 4.0 us / call
(2) User Guide without patch, same operation
90037 calls, 0.25 s, 2.8 us / call
Total run time approx 180 s in both cases. Typing the a's took some 20
s.

My own lecture notes (almost 3x the size of the User Guide, 350 p
printed)
(1) With the patch, above operation
98995 calls, 0.25 s, 2.5 us / call
(2) Without the patch
98995 calls, 0.23 s, 2.3 us / call
Total run time 380 s. Big file.

So the patch seems to make getFont a little slower, but not unduly so,
confirming my earlier observations comparing typing in the beginning vs.
the end of the User Guide.

Note the considerable uncertainty in these measurements.

Is this the info you were after?

I suspect BTW that gcc optimises out the loop when pars_ is a vector,
just like Jean-Marc proposed to do manually ;-) If we change the
container type, all bets are off, but I suppose that would then be part
of a bigger refactoring anyway.


> else not.
> 
> but IMHO we should stop with the speed/flickering games for 1.4.0.

...but I _like_ playing games! And you can't say I haven't fixed my
share of bugs... and when 1.4.1 time comes, I'm ready ;-)

BTW what's holding up 1.4.0 right now?

- Martin

Attachment: pgpVUEEKKKLCC.pgp
Description: PGP signature

Reply via email to