Carl Friedrich Bolz avatar Carl Friedrich Bolz committed 36db01d

(cfbolz, lac): remove outdated references to 2.2, 2.3, 2.4 and 2.5. some fixes in getting-started

Comments (0)

Files changed (7)

pypy/doc/cli-backend.rst

 for .NET; the only version tested with PyPy is the 1.0-rc2, but it
 might work also with others. Then, you need to create a file named
 Python.Runtime.dll.config at the root of the unpacked archive; put the
-following lines inside the file (assuming you are using Python 2.4)::
+following lines inside the file (assuming you are using Python 2.7)::
 
   <configuration>
-    <dllmap dll="python24" target="libpython2.4.so.1.0" os="!windows"/>
+    <dllmap dll="python27" target="libpython2.7.so.1.0" os="!windows"/>
   </configuration>
 
 The installation should be complete now. To run Python for .NET,

pypy/doc/coding-guide.rst

 -------------------------
 
 While implementing the integer type, we stumbled over the problem that
-integers are quite in flux in CPython right now. Starting on Python 2.2,
-integers mutate into longs on overflow.  However, shifting to the left
-truncates up to 2.3 but extends to longs as well in 2.4.  By contrast, we need
+integers are quite in flux in CPython right now. Starting with Python 2.4,
+integers mutate into longs on overflow.  In contrast, we need
 a way to perform wrap-around machine-sized arithmetic by default, while still
 being able to check for overflow when we need it explicitly.  Moreover, we need
 a consistent behavior before and after translation.
   ovfcheck() as a hint: they replace the whole ``ovfcheck(x+y)`` expression
   with a single overflow-checking addition in C.
 
-**ovfcheck_lshift()**
-
-  ovfcheck_lshift(x, y) is a workaround for ovfcheck(x<<y), because the
-  latter doesn't quite work in Python prior to 2.4, where the expression
-  ``x<<y`` will never return a long if the input arguments are ints.  There is
-  a specific function ovfcheck_lshift() to use instead of some convoluted
-  expression like ``x*2**y`` so that code generators can still recognize it as
-  a single simple operation.
-
 **intmask()**
 
   This function is used for wrap-around arithmetic.  It returns the lower bits
 
 Modules visible from application programs are imported from
 interpreter or application level files.  PyPy reuses almost all python
-modules of CPython's standard library, currently from version 2.5.2.  We
+modules of CPython's standard library, currently from version 2.7.1.  We
 sometimes need to `modify modules`_ and - more often - regression tests
 because they rely on implementation details of CPython.
 

pypy/doc/getting-started-dev.rst

    interpreter are defined in `pypy/interpreter/typedef.py`_.
 
 *  `pypy/interpreter/pyparser`_ contains a recursive descent parser,
-   and input data files that allow it to parse both Python 2.3 and 2.4
-   syntax.  Once the input data has been processed, the parser can be
+   and input data files that allow it to parse the syntax of various Python
+   versions. Once the input data has been processed, the parser can be
    translated by the above machinery into efficient code.
  
 *  `pypy/interpreter/astcompiler`_ contains the compiler.  This
 
 	pygame: http://www.pygame.org/download.shtml
 
-CTypes on Python 2.4
-++++++++++++++++++++++++++++
-
-`ctypes`_ is included in CPython 2.5 and higher.  CPython 2.4 users needs to
-install it if they want to run low-level tests. See
-the `download page of ctypes`_.
-
-.. _`download page of ctypes`: https://sourceforge.net/projects/ctypes/files/
-.. _`ctypes`: http://starship.python.net/crew/theller/ctypes/
-
-.. _`py.test`:
-
 py.test and the py lib 
 +++++++++++++++++++++++
 

pypy/doc/getting-started-python.rst

 To actually use PyPy's Python interpreter, the first thing to do is to 
 `download a pre-built PyPy`_ for your architecture.  
 
-.. `download a pre-built PyPy`:  http://pypy.org/download.html
+.. _`download a pre-built PyPy`:  http://pypy.org/download.html
 
 Translating the PyPy Python interpreter
 ---------------------------------------
 .. _`windows document`: windows.html
 
 You can translate the whole of PyPy's Python interpreter to low level C code,
-`CLI code`_, or `JVM code`_.
+or `CLI code`_.
 
 1. First `download a pre-built PyPy`_ for your architecture which you will
-use to translate your Python interpreter.  It is, of course, possible to
-translate with a CPython 2.6 or later, but this is not the preferred way,
-because it will take a lot longer to run -- depending on your architecture,
-between two and three times as long.
+   use to translate your Python interpreter.  It is, of course, possible to
+   translate with a CPython 2.6 or later, but this is not the preferred way,
+   because it will take a lot longer to run -- depending on your architecture,
+   between two and three times as long.
 
 2. Install build-time dependencies.  On a Debian box these are::
 
    * ``python-sphinx`` (for the optional documentation build.  You need version 1.0.7 or later)
    * ``python-greenlet`` (for the optional stackless support in interpreted mode/testing)
 
+
 3. Translation is time-consuming -- 45 minutes on a very fast machine --
    and RAM-hungry.  As of March 2011, you will need **at least** 2 GB of 
    memory on a 
    are constrained, or your machine is slow you might want to pick the
    `optimization level`_ `1` in the next step.  A level of
    `2` or `3` or `jit` gives much better results, though.  But if all
-    you want to do is to test that some new feature that you just wrote
-    translates, level 1 is enough.
+   you want to do is to test that some new feature that you just wrote
+   translates, level 1 is enough.
 
    Let me stress this again: at ``--opt=1`` you get the Boehm
    GC, which is here mostly for historical and for testing reasons.
 
    possibly replacing ``--opt=jit`` with another `optimization level`_
    of your choice like ``--opt=2`` if you do not want to include the JIT
-   compiler.  
+   compiler, which makes the Python interpreter much slower.  
 
 .. _`optimization level`: config/opt.html
 
 executable. The executable behaves mostly like a normal Python interpreter::
 
     $ ./pypy-c
-    Python 2.5.2 (64177, Apr 16 2009, 16:33:13)
-    [PyPy 1.1.0] on linux2
+    Python 2.7.0 (61ef2a11b56a, Mar 02 2011, 03:00:11)
+    [PyPy 1.5.0-alpha0 with GCC 4.4.3] on linux2
     Type "help", "copyright", "credits" or "license" for more information.
     And now for something completely different: ``this sentence is false''
     >>>> 46 - 4
     42
     >>>> from test import pystone
     >>>> pystone.main()
-    Pystone(1.1) time for 50000 passes = 2.57
-    This machine benchmarks at 19455.3 pystones/second
+    Pystone(1.1) time for 50000 passes = 0.280017
+    This machine benchmarks at 178561 pystones/second
     >>>>
 
 This executable can be moved around or copied on other machines; see
-Installation_ below.  For now a JIT-enabled ``pypy-c`` always produces
-debugging output to stderr when it exits, unless translated with
-``--jit-debug=off``.
+Installation_ below.
 
 The ``translate.py`` script takes a very large number of options controlling
 what to translate and how.  See ``translate.py -h``. Some of the more
 ++++++++++++++++++++++++++++++++++++++++
 
 It is possible to have non-standard features enabled for translation,
-but they are not really tested any more.  Look for example at the
+but they are not really tested any more.  Look, for example, at the
 `objspace proxies`_ document.
 
 .. _`objspace proxies`: objspace-proxies.html
 the convenience ./pypy-cli script::
 
     $ ./pypy-cli
-    Python 2.5.2 (64219, Apr 17 2009, 13:54:38)
-    [PyPy 1.1.0] on linux2
+    Python 2.7.0 (61ef2a11b56a, Mar 02 2011, 03:00:11)
+    [PyPy 1.5.0-alpha0] on linux2
     Type "help", "copyright", "credits" or "license" for more information.
     And now for something completely different: ``distopian and utopian chairs''
     >>>> 
 To try out the experimental .NET integration, check the documentation of the
 clr_ module.
 
-.. _`JVM code`: 
+..  not working now:
 
-Translating using the JVM backend
-+++++++++++++++++++++++++++++++++
+    .. _`JVM code`: 
 
-To create a standalone JVM executable::
+    Translating using the JVM backend
+    +++++++++++++++++++++++++++++++++
 
-    ./translate.py --backend=jvm targetpypystandalone.py
+    To create a standalone JVM executable::
 
-This will create a jar file ``pypy-jvm.jar`` as well as a convenience
-script ``pypy-jvm`` for executing it.  To try it out, simply run
-``./pypy-jvm``::
+        ./translate.py --backend=jvm targetpypystandalone.py
 
-    $ ./pypy-jvm 
-    Python 2.5.2 (64214, Apr 17 2009, 08:11:23)
-    [PyPy 1.1.0] on darwin
-    Type "help", "copyright", "credits" or "license" for more information.
-    And now for something completely different: ``# assert did not crash''
-    >>>> 
+    This will create a jar file ``pypy-jvm.jar`` as well as a convenience
+    script ``pypy-jvm`` for executing it.  To try it out, simply run
+    ``./pypy-jvm``::
 
-Alternatively, you can run it using ``java -jar pypy-jvm.jar``. At the moment
-the executable does not provide any interesting features, like integration with
-Java.
+        $ ./pypy-jvm 
+        Python 2.7.0 (61ef2a11b56a, Mar 02 2011, 03:00:11)
+        [PyPy 1.5.0-alpha0] on linux2
+        Type "help", "copyright", "credits" or "license" for more information.
+        And now for something completely different: ``# assert did not crash''
+        >>>> 
+
+    Alternatively, you can run it using ``java -jar pypy-jvm.jar``. At the moment
+    the executable does not provide any interesting features, like integration with
+    Java.
 
 Installation
 ++++++++++++
 
 For installation purposes, note that the executable needs to be able to
 find its version of the Python standard library in the following three
-directories: ``lib-python/2.5.2``, ``lib-python/modified-2.5.2`` and
+directories: ``lib-python/2.7``, ``lib-python/modified-2.7`` and
 ``lib_pypy``.  They are located by "looking around" starting from the
 directory in which the executable resides.  The current logic is to try
 to find a ``PREFIX`` from which the directories
-``PREFIX/lib-python/2.5.2`` and ``PREFIX/lib-python/modified.2.5.2`` and
+``PREFIX/lib-python/2.7`` and ``PREFIX/lib-python/modified.2.7`` and
 ``PREFIX/lib_pypy`` can all be found.  The prefixes that are tried are::
 
     .
     ...
     $ bin/easy_install WebOb
     $ bin/pypy-c           
-    Python 2.5.2 (64714, Apr 27 2009, 08:16:13)
-    [PyPy 1.1.0] on linux2
+    Python 2.7.0 (61ef2a11b56a, Mar 02 2011, 03:00:11)
+    [PyPy 1.5.0-alpha0 with GCC 4.4.3] on linux2
     Type "help", "copyright", "credits" or "license" for more information.
     And now for something completely different: ``PyPy doesn't have copolyvariadic dependently-monomorphed hyperfluxads''
     >>>> import webob
 +++++++++++++++++++++
 
 To start interpreting Python with PyPy, install a C compiler that is
-supported by distutils and use Python 2.4 or greater to run PyPy::
+supported by distutils and use Python 2.5 or greater to run PyPy::
 
     cd pypy
     python bin/py.py
 Alternatively, as with regular Python, you can simply give a
 script name on the command line::
 
-    python py.py ../../lib-python/2.5.2/test/pystone.py 10
+    python py.py ../../lib-python/2.7/test/pystone.py 10
 
 See our  `configuration sections`_ for details about what all the commandline
 options do.

pypy/doc/index.rst

 Getting into PyPy ... 
 =============================================
 
-* `Release 1.4`_: the latest official release
+* `Release 1.5`_: the latest official release
 
 * `PyPy Blog`_: news and status info about PyPy 
 
 .. _`Getting Started`: getting-started.html
 .. _`Papers`: extradoc.html
 .. _`Videos`: video-index.html
-.. _`Release 1.4`: http://pypy.org/download.html
+.. _`Release 1.5`: http://pypy.org/download.html
 .. _`speed.pypy.org`: http://speed.pypy.org
 .. _`RPython toolchain`: translation.html
 

pypy/doc/interpreter-optimizations.rst

 
     $ bin/py.py --objspace-std-withrope
     faking <type 'module'>
-    PyPy 0.99.0 in StdObjSpace on top of Python 2.4.4c1 (startuptime: 17.24 secs)
+    PyPy 1.5.0-alpha0 in StdObjSpace on top of Python 2.7.1+ (startuptime: 11.38 secs)
     >>>> import sys
     >>>> sys.maxint
     2147483647

pypy/doc/interpreter.rst

 
 Code objects are a nicely preprocessed, structured representation of
 source code, and their main content is *bytecode*.  We use the same
-compact bytecode format as CPython 2.4.  Our bytecode compiler is
+compact bytecode format as CPython 2.7, with minor differences in the bytecode
+set.  Our bytecode compiler is
 implemented as a chain of flexible passes (tokenizer, lexer, parser,
 abstract syntax tree builder, bytecode generator).  The latter passes
 are based on the ``compiler`` package from the standard library of
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.