[pypy-dev] pypy-c and JIT

Christian Tismer tismer at stackless.com
Mon Oct 22 17:03:52 CEST 2007

Armin Rigo wrote:
> Hi Raj,
> On Sun, Oct 21, 2007 at 08:55:12AM -0500, Raj Bandyopadhyay wrote:
>> It only worked for me when I cd'ed to the pypy-1.0.0 directory and  
>> ran pypy-c there.
>> When I added pypy-1.0.0 to my path and ran pypy-c from somewhere  
>> else, it gave me errors saying that some modules are not found. This  
>> could definitely be a result of my inexperience with windows, but if  
>> you get a chance, please do test it out.
> Ok.  For anyone interested in helping out, the relevant code is in
> translator/goal/app_main.py.  In particular, on Unix at least, the 10
> first lines of entry_point() look if sys.argv[0] contains no '/' and if
> so search along the $PATH for the likely full path to the executable.
> After a quick look the same code appears ok for Windows too, but clearly
> something goes wrong somewhere.  A way to check if these 10 lines worked
> is to print sys.executable from the command-line of pypy-c.

Ok, I checked again.
One fault of mine was that I happened to have another pypy-c.exe
executable around. So actually, I now also crash with the import

Python 2.4.1 (pypy 1.0.0 build 41438) on win32
Type "help", "copyright", "credits" or "license" for more information.
Error calling sys.excepthook:
debug: OperationError:
debug:  operror-type: ImportError
debug:  operror-value: No module named traceback

Then I tested what you said from the command line:

C:\Dokumente und Einstellungen\tismer.MACGYVERXP>pypy-c.exe -c "import 
sys; print sys.executable"
debug: WARNING: library path not found, using compiled-in sys.path
C:\Dokumente und Einstellungen\tismer.MACGYVERXP\pypy-c.exe

This is in fact nonsense, the executable came from the temp
directory mentioned before, all other pypy-c's were removed.

So something is wrong, and I'm looking into this.

cheers - chris
Christian Tismer             :^)   <mailto:tismer at stackless.com>
tismerysoft GmbH             :     Have a break! Take a ride on Python's
Johannes-Niemeyer-Weg 9A     :    *Starship* http://starship.python.net/
14109 Berlin                 :     PGP key -> http://wwwkeys.pgp.net/
work +49 30 802 86 56  mobile +49 173 24 18 776  fax +49 30 80 90 57 05
PGP 0x57F3BF04       9064 F4E1 D754 C2FF 1619  305B C09C 5A3B 57F3 BF04
       whom do you want to sponsor today?   http://www.stackless.com/

More information about the Pypy-dev mailing list