Re: Python pyc/pyo (Was: Inflation)

2007-07-06 Thread Bernardo Innocenti
Mike C. Fletcher wrote: My understanding is that slowdown is seen due to large number of stats during module import. I made a few experiments and it turns out that, on a slow B2, it takes only 182ms to stat all the 2500 files in /usr/lib/python2.5. I also analyzed what happens when we do

Re: Python pyc/pyo (Was: Inflation)

2007-07-04 Thread Bernardo Innocenti
Pádraig Brady wrote: For example there are many duplicate py[oc] files, Yeah, do we really have to ship pyc nd pyo files? They're sometimes even bigger than the source code, probably due to the full blown UTF-32 strings. No other dynamic language needs that pre-tokenized junk. Is Python so

Re: Python pyc/pyo (Was: Inflation)

2007-07-04 Thread Mike C. Fletcher
Bernardo Innocenti wrote: ... No other dynamic language needs that pre-tokenized junk. Is Python so slow at parsing? Has anybody measured the hit? There is some minor improvement in speed from the cached byte code. That said, there's no reason to *ship* them, you can run a compileall