[pypy-dev] JIT Failure on lltype.Array access

Dan Roberts ademan555 at gmail.com
Mon Aug 16 01:18:10 CEST 2010


As best I can tell, the JIT cannot handle my code properly, it corrupts
memory and returns 0.0 for float arrays. I don't know whether the true
problem is in my code or the JIT, but I need to get this resolved quickly.

I know the JIT and my code are interacting badly because py.py works fine
(though slow) and translated pypy-c with jit and --jit threshold=9999999
both work fine.

Here's what I've tried to resolve the issue:
Removing my _immutable_fields_ hints.
Hand implementing bh_{get,set}arrayitem_raw_{r,i,f} (though I don't know my
implementation was right, I simply copied the gc version and removed the
first offset (since raw arrays have no header right? Although I expect that
the gc version would have simply gotten 0 for the header size... I tried it
anyways)

A few thoughts:
descr.py alludes to a FloatArrayDescr which I never raw defined
Could the asm backend be part of the problem? Rather than the code in
llmodel.py?

Unfortunately I'm ill equipped to resolve this issue, so any help is
appreciated (I'm on my phone but I'll happily furnish exact errors upon
request)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/pypy-dev/attachments/20100815/b57c1dfb/attachment.html>


More information about the Pypy-dev mailing list