[Python-Dev] New opcode to simplifiy/speedup list comprehensions (original) (raw)
Aahz aahz at pythoncraft.com
Sat Mar 6 09:41:10 EST 2004
- Previous message: [Python-Dev] New opcode to simplifiy/speedup list comprehensions
- Next message: [Python-Dev] New opcode to simplifiy/speedup list comprehensions
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Sat, Mar 06, 2004, Raymond Hettinger wrote:
If there are no objections, I would like to add an opcode for calling PyListAppend(). This simplifies the generated code for list comprehensions and reduces the overhead on each pass, improving the timings by about 35% on [i for i in itertools.repeat(None, 500)].
Not objections per se, but every ceval.c gets mucked with, it has a tendency to change overall speed. Have you checked Python benchmarks on at least two platforms?
Aahz (aahz at pythoncraft.com) <*> http://www.pythoncraft.com/
"Do not taunt happy fun for loops. Do not change lists you are looping over." --Remco Gerlich, comp.lang.python
- Previous message: [Python-Dev] New opcode to simplifiy/speedup list comprehensions
- Next message: [Python-Dev] New opcode to simplifiy/speedup list comprehensions
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]