I profiled Psyco itself with gprof (by compiling it into Python 2.2c1 as a
static module). The code produced by Psyco is not recognized by the
profiler, but we can still measure the time spent in the various compiling
functions. The result is very clear: in a 10- or 100-iterations pystone,
70% of the time is spent in dispatcher.c's "compatible_array()" function
whose purpose is to look for a match between the compiler state and a
previously encountered state.
This corresponds to the comments in dispatcher.h about "Global entries".
This must be optimized (hash tables, search trees,...). I believe this can
be brought down to a much more reasonable figure of a few percents of the