Commits

tilarids  committed 47be706

Updated getting-started-dev.rst doc and fixed some broken links

* Docs for several RPython env vars were added
* translatorshell.py sets sys.path correctly now
* Broken extradoc link was fixed

  • Participants
  • Parent commits 997a2d3

Comments (0)

Files changed (4)

File pypy/doc/getting-started-dev.rst

 
 There is a small-to-medium demo showing the translator and the annotator::
 
-    cd demo
-    ../rpython/translator/goal/translate.py --view --annotate bpnn.py
+    python bin/rpython --view --annotate translator/goal/bpnn.py
 
 This causes ``bpnn.py`` to display itself as a call graph and class
 hierarchy.  Clicking on functions shows the flow graph of the particular
 To turn this example to C code (compiled to the executable ``bpnn-c``),
 type simply::
 
-    ../rpython/translator/goal/translate.py bpnn.py
+    python bin/rpython translator/goal/bpnn.py
 
 
 Translating Full Programs
 ``rpython/translator/goal``. Examples for this are a slightly changed version of
 Pystone::
 
-    cd rpython/translator/goal
-    python translate.py targetrpystonedalone
+    python bin/rpython translator/goal/targetrpystonedalone
 
 This will produce the executable "targetrpystonedalone-c".
 
 interpreter`_. There is also an FAQ about how to set up this process for `your
 own interpreters`_.
 
+There are several environment variables you can find useful while playing with the RPython:
+
+``PYPY_USESSION_DIR``
+    RPython uses temporary session directories to store files that are generated during the 
+    translation process(e.g., translated C files). ``PYPY_USESSION_DIR`` serves as a base directory for these session
+    dirs. The default value for this variable is the systems temporary dir.
+
+``PYPY_USESSION_KEEP``
+    By default RPython keeps only last ``PYPY_USESSION_KEEP`` (defaults to 3) session dirs inside ``PYPY_USESSION_DIR``. 
+    Increase this value if you want your C files to preserve (useful when producing lots of lldebug builds)
+
 .. _`your own interpreters`: faq.html#how-do-i-compile-my-own-interpreters
 
 .. _`start reading sources`: 

File pypy/doc/jit/pyjitpl5.rst

 implemented.  It's helpful to have an understanding of how the `RPython translation
 toolchain`_ works before digging into the sources.
 
-Almost all JIT specific code is found in pypy/jit subdirectories.  Translation
+Almost all JIT specific code is found in rpython/jit subdirectories.  Translation
 time code is in the codewriter directory.  The metainterp directory holds
 platform independent code including the the tracer and the optimizer.  Code in
 the backend directory is responsible for generating machine code.
 
 * `Tracing the Meta-Level: PyPy's Tracing JIT Compiler`__
 
-.. __: http://codespeak.net/svn/pypy/extradoc/talk/icooolps2009/bolz-tracing-jit-final.pdf
+.. __: https://bitbucket.org/pypy/extradoc/src/tip/talk/icooolps2009/bolz-tracing-jit-final.pdf
 
 as well as the `blog posts with the JIT tag.`__
 

File rpython/bin/translatorshell.py

 """
 
 import os, sys
+sys.path.insert(0, os.path.dirname(os.path.dirname(
+                       os.path.dirname(os.path.realpath(__file__)))))
 
 from rpython.translator.interactive import Translation
 from rpython.rtyper.rtyper import *

File rpython/translator/goal/bpnn.py

 import math
 import time
 
-import autopath
 from rpython.rlib import rrandom
 
 PRINT_IT = True