>The problem, though, is that I don't know how to put multiple DirLists
>in a single window. Or is it plain impossible? (In that case: bye,
>bye, stdwin. :-)
Check out the HVSplit module, this lets you build an arbitrary widget
>What I'm missing is a high level abstraction model for "accepted" user
>interface objects, such as dialog boxes with elements such as a listbox.
There are remarkably many of these and it is remarkably hard to make
them general enough -- again, see the size of Motif and Windows.
>Now *that* is an interesting assumption. I compiled in the optional
>malloc library which implements the bucket algorithm. And lo and behold,
>it is much better, but not close to what you show. It lookes like the
>size of the directory is also pretty important...
Of course it is, if the algorithm is O(n**2)... Unfirtunately I have
little idea of what to do about this particular problem. Anybody
know about a really fast malloc library? I seem to remember that the
best ones keep separate free lists per size, rounded to powers of two.
> %Time Seconds Cumsecs #Calls msec/call Name
> 21.6 16.58 16.58 23698 0.6997 newdictobject
> 15.6 11.97 28.56 23182 0.5165 eval_code
> 10.5 8.03 36.58 262848 0.0305 malloc
> 10.4 7.97 44.55 _mcount
> 4.8 3.70 48.25 262277 0.0141 free
> 3.4 2.58 50.83 582599 0.0044 strcmp
> 3.3 2.52 53.35 34252 0.0736 call_object
Hmm, the newdictobject on top is suspicious, it doesn't do anything
that could take 0.7 msec. I suspect its time may include the time
taken by lookdict(), the next function in the file which happens to be
static and is used for every local variable reference (most calls to
strcmp() come from there I would guess). Don't you have a more modern
profiler, e.g. gprof? The number of eval_code calls (the main
interpreter loop) reflects mostly the number of function calls, and
most newdictobject() calls are for the dictionaries of local variables.
(I suppose there's an opportunity for a code optimizer here. :-)
That's my two cents worth for now...
--Guido van Rossum, CWI, Amsterdam <email@example.com>
"Did you say knives?"
"Rotating knives, yes"