Hallo, I found another difference in bahaviour between py.py and pypy-c with my set implementation enabled. The 'ior' operator in pypy-c does not behave as expected. My first thought was, that somehow the rdict.update method does not work as expected, but translator/goal/targetrdicttest2.py behaves, as it should, so there goes that theory. I have no idea whatsoever, where to look next. Stephan --------------------- py.py ----------------------------------------- [stephan@bach pypy]$ bin/py.py Loading grammar /home/stephan/projects/pypy-dist/pypy/interpreter/pyparser/data/Grammar2.5a faking <type 'module'> faking <type 'file'> fake-wrapping interp file <open file '<stdout>', mode 'w' at 0xb7f82068> fake-wrapping interp file <open file '<stderr>', mode 'w' at 0xb7f820b0> fake-wrapping interp file <open file '<stdin>', mode 'r' at 0xb7f82020> PyPy 0.8.0 in StdObjSpace on top of Python 2.4.1 (startuptime: 2.31 secs)
w1 = 'test' w2 = 'stat' s = set(w1) t = set(w2) s set(['s', 'e', 't']) t set(['a', 's', 't']) s |= t s set(['a', 's', 'e', 't']) s = set(w1) s &= t s set(['s', 't'])
--------------------- pypy-c --------------------------------------- [stephan@bach stephan]$ pypy-c debug: entry point starting debug: argv -> pypy-c debug: importing code debug: calling code.interact() Python 2.4.1 (pypy 0.8.0 build 26169) on linux2 Type "help", "copyright", "credits" or "license" for more information. (InteractiveConsole)
w1 = 'test' w2 = 'stat' s = set(w1) t = set(w2) s set(['s', 'e', 't']) t set(['a', 's', 't']) s |= t s set(['s', 'e', 't']) s = set(w1) s &= t s set(['s', 't'])
Hi Stephan, On Sun, Apr 23, 2006 at 01:57:45PM +0200, Stephan Diehl wrote:
I found another difference in bahaviour between py.py and pypy-c with my set implementation enabled.
Sorry for taking so long to investigate. It turned out to be a bug indirectly related to inlining, which caused wrong code to be generated. In short the calls to _union_dict() with isupdate=True were inlined, and the inlined version was incorrectly following the isupdate=False path... It should be fixed now. A bientot, Armin.
Hi Armin, On Wednesday 26 April 2006 21:33, Armin Rigo wrote:
Hi Stephan,
On Sun, Apr 23, 2006 at 01:57:45PM +0200, Stephan Diehl wrote:
I found another difference in bahaviour between py.py and pypy-c with my set implementation enabled.
Sorry for taking so long to investigate.
Please don't worry. I'm actually amazed how fast you always come up with a solution (and do tons of other stuff as well).
It turned out to be a bug indirectly related to inlining, which caused wrong code to be generated. In short the calls to _union_dict() with isupdate=True were inlined, and the inlined version was incorrectly following the isupdate=False path... It should be fixed now.
It is fixed. Thanks a lot. Cheers Stephan
A bientot,
Armin.
participants (2)
-
Armin Rigo
-
Stephan Diehl