[pypy-dev] Questions from a lurker

Arthur Peters amp at singingwizard.org
Sat Jul 16 00:29:51 CEST 2005

Hello, I am Arthur. I've been lurking on the list for a month or so and
I've had a good bit of fun playing with the code.

My questions are:

- Why did you start a second LLVM backend? Was the first one badly miss

- So I take it the initial goal will be to translate pypy into C (or
LLVM) and create a binary executable. At that point will it be possible
to translate any given program or will the translator still only work
with a subset of the python language? Will the final goal be a JIT VM
for python or will I at some point be able to statically compile python
to machine code?

- Will there be support for multiple specialized versions of functions
like in psyco? I know this is a long way down the road but I'm curious
what people think.

- I read what some discussion of the GIL as it relate to pypy and I agree
that the GIL need to be implemented and that a different thread model
might be a good way to go. However I thought of the following: Would it
be possible to detect when a section of code only uses local variables
and unlock the GIL? This seems possible because local variables will
cannot be shared between threads anyway. In addition, local variables
likely be translated into more basic types than a python object (native
ints and floats for instance), that would not require any interaction
with the object-space to manipulate (not sure about that usage of the
term "object-space"). Thoughts?

- I have tried to run test_all.py on my desktop (a dual PIII running
ubuntu breazy (development)) but I get the following exception:
Traceback (most recent call last):
  File "pypy/test_all.py", line 6, in ?
  File "/home/amp/source/pypy-dist/py/test/cmdline.py", line 8, in main
    config, args = py.test.Config.parse(py.std.sys.argv[1:])
  File "/home/amp/source/pypy-dist/py/test/config.py", line 61, in parse
    config = bootstrapconfig(configpaths)
  File "/home/amp/source/pypy-dist/py/test/config.py", line 168, in
  File "/home/amp/source/pypy-dist/py/test/config.py", line 91, in
    mod = importconfig(configpath)
  File "/home/amp/source/pypy-dist/py/test/config.py", line 208, in
    return configpath.pyimport()
  File "/home/amp/source/pypy-dist/py/path/local/local.py", line 381,
in pyimport
    return __import__(modname, None, None, ['__doc__'])
ImportError: No module named defaultconftest

The cause of the problem seems to be a failure at
/home/amp/source/pypy-dist/py/initpkg.py(179)__getattr__() while trying
to get the attribute "__path__". This happens on both 2.3 and 2.4.
This does not happen at all on my Ubuntu Hoary (stable) laptop.

Any ideas?

Thanks a bunch. I am very impressed by what pypy can do and I'm looking
forward to seeing it progress.


PS: I am the amep that left a message on IRC.

More information about the Pypy-dev mailing list