Re: [Python-Dev] Opcode frequency

2008-06-19 Thread Maciej Fijalkowski
On Thu, Jun 19, 2008 at 1:03 AM, Raymond Hettinger <[EMAIL PROTECTED]> wrote: >> Maciej Fijalkowski did an opcode analysis for PyPy, >> it also shows the relative frequency of opcodes following a >> specifc one: >> >> http://codespeak.net/svn/user/fijal/opcodes.txt >> >> Might it make sense to add

Re: [Python-Dev] Opcode frequency

2008-06-18 Thread Raymond Hettinger
Maciej Fijalkowski did an opcode analysis for PyPy, it also shows the relative frequency of opcodes following a specifc one: http://codespeak.net/svn/user/fijal/opcodes.txt Might it make sense to add more PREDICT()ions based on this, e.g. for BUILD_SLICE -> BINARY_SUBSCR? This particular one m

Re: [Python-Dev] Opcode frequency

2008-06-18 Thread Carl Friedrich Bolz
Georg Brandl wrote: > Antoine Pitrou schrieb: >>> Maciej Fijalkowski did an opcode analysis for PyPy, >>> it also shows the relative frequency of opcodes following a >>> specifc one: >>> >>> http://codespeak.net/svn/user/fijal/opcodes.txt >> >> Nice, but we have to be careful here: what is the test

Re: [Python-Dev] Opcode frequency

2008-06-18 Thread Antoine Pitrou
Georg Brandl gmx.net> writes: > Agreed; is there a way for a JUMP to end up without popping the top > after jumping? It would have to do a DUP first then. For example: >>> def f(x, y): ... return x and y ... >>> import dis >>> dis.dis(f) 2 0 LOAD_FAST0 (x)

Re: [Python-Dev] Opcode frequency

2008-06-18 Thread Georg Brandl
Antoine Pitrou schrieb: Hi, Maciej Fijalkowski did an opcode analysis for PyPy, it also shows the relative frequency of opcodes following a specifc one: http://codespeak.net/svn/user/fijal/opcodes.txt Nice, but we have to be careful here: what is the tested workload? For example, I find it h

Re: [Python-Dev] Opcode frequency

2008-06-18 Thread Antoine Pitrou
Hi, > Maciej Fijalkowski did an opcode analysis for PyPy, > it also shows the relative frequency of opcodes following a > specifc one: > > http://codespeak.net/svn/user/fijal/opcodes.txt Nice, but we have to be careful here: what is the tested workload? For example, I find it hard to believe th

[Python-Dev] Opcode frequency

2008-06-18 Thread Georg Brandl
Hi, Maciej Fijalkowski did an opcode analysis for PyPy, it also shows the relative frequency of opcodes following a specifc one: http://codespeak.net/svn/user/fijal/opcodes.txt Might it make sense to add more PREDICT()ions based on this, e.g. for BUILD_SLICE -> BINARY_SUBSCR? Georg __