Commit ddef8f08 authored by Jason Madden's avatar Jason Madden

documentation tweaks, around cffi and pypy versions. [skip ci]

parent 27fe978d
...@@ -43,10 +43,14 @@ Development ...@@ -43,10 +43,14 @@ Development
To install the latest development version:: To install the latest development version::
pip install setuptools 'cython>=0.23.4' git+git://github.com/gevent/gevent.git#egg=gevent pip install setuptools cffi tox 'cython>=0.23.4' git+git://github.com/gevent/gevent.git#egg=gevent
.. note:: You must have Cython, a C compiler, and the Python .. note::
development headers installed to build a checkout. You must have Cython, a C compiler, and the Python
development headers installed to build a checkout. Installing CFFI
on CPython (it's standard on PyPy) allows building the CFFI backend
for testing, and tox is the command used to test multiple versions
of Python.
Running Tests Running Tests
------------- -------------
...@@ -54,8 +58,7 @@ Running Tests ...@@ -54,8 +58,7 @@ Running Tests
There are a few different ways to run the tests. To simply run the There are a few different ways to run the tests. To simply run the
tests on one version of Python during development, try this:: tests on one version of Python during development, try this::
pip install setuptools cython>=0.23.4 python setup.py develop
python setup.py build
cd greentest cd greentest
PYTHONPATH=.. python testrunner.py --config ../known_failures.py PYTHONPATH=.. python testrunner.py --config ../known_failures.py
......
...@@ -20,5 +20,5 @@ Python 3, Python 2.7.9 and above, and Python 2.7.8 and below, respectively. ...@@ -20,5 +20,5 @@ Python 3, Python 2.7.9 and above, and Python 2.7.8 and below, respectively.
.. toctree:: .. toctree::
Python 3 interface <gevent._ssl3> Python 3 interface <gevent._ssl3>
Python 2.7.9 and above interface (including PyPy 2.6.0) <gevent._sslgte279> Python 2.7.9 and above interface (including PyPy 2.6.1 and above) <gevent._sslgte279>
Python 2.7.8 and below interface (including PyPy 2.5.0) <gevent._ssl2> Python 2.7.8 and below interface <gevent._ssl2>
...@@ -30,17 +30,23 @@ supported. (Users of older versions of Python need to install gevent ...@@ -30,17 +30,23 @@ supported. (Users of older versions of Python need to install gevent
gevent 1.1 also runs on PyPy 2.6.1 and above, although 4.0 or above is gevent 1.1 also runs on PyPy 2.6.1 and above, although 4.0 or above is
strongly recommended. On PyPy, there are no external dependencies. strongly recommended. On PyPy, there are no external dependencies.
.. note:: gevent does *not* run on PyPy on Windows as the CFFI backend
does not build.
gevent and greenlet can both be installed with `pip`_, e.g., ``pip gevent and greenlet can both be installed with `pip`_, e.g., ``pip
install gevent``. On Windows and OS X, both gevent and greenlet are install gevent``. On Windows and OS X, both gevent and greenlet are
distributed as binary `wheels`_, so no C compiler is required (so long distributed as binary `wheels`_, so no C compiler is required (so long
as pip is at least version 1.4). On Linux or for Mac OS X variants as pip is at least version 1.4). On Linux or for Mac OS X variants
without pre-built wheels or if wheel installation is disabled, a C compiler without pre-built wheels or if wheel installation is disabled, a C compiler
(Xcode on OS X) and the Python development package are required. (Xcode on OS X) and the Python development package are required.
`cffi`_ can optionally be installed to build the CFFI backend in
addition to the Cython backend on CPython.
__ http://pypi.python.org/pypi/greenlet __ http://pypi.python.org/pypi/greenlet
.. _`pip`: https://pip.pypa.io/en/stable/installing/ .. _`pip`: https://pip.pypa.io/en/stable/installing/
.. _`wheels`: http://pythonwheels.com .. _`wheels`: http://pythonwheels.com
.. _`gevent 1.1`: whatsnew_1_1.html .. _`gevent 1.1`: whatsnew_1_1.html
.. _`cffi`: http://cffi.readthedocs.org
Example Example
======= =======
......
...@@ -10,8 +10,8 @@ Platform Support ...@@ -10,8 +10,8 @@ Platform Support
================ ================
gevent 1.1 supports Python 2.6, 2.7, 3.3, and 3.4 on the CPython gevent 1.1 supports Python 2.6, 2.7, 3.3, and 3.4 on the CPython
(`python.org`_) interpreter. It also supports `PyPy`_ 2.5.0 and above (with (`python.org`_) interpreter. It also supports `PyPy`_ 2.6.1 and above (with
best results being obtained on PyPy 2.6.1 and above); PyPy3 is not best results being obtained on PyPy 4.0.1 and above); PyPy3 is not
supported. supported.
Support for Python 2.5 was removed when support for Python 3 was Support for Python 2.5 was removed when support for Python 3 was
...@@ -39,17 +39,18 @@ through 4.0.0 and 4.0.1. ...@@ -39,17 +39,18 @@ through 4.0.0 and 4.0.1.
.. note:: PyPy is not supported on Windows. .. note:: PyPy is not supported on Windows.
- Version 2.6.1 or above is required for the most robust signal - Version 2.6.1 or above is required for proper signal handling. Prior
handling. Prior to 2.6.1 and its inclusion of `cffi 1.3.0`_, signals to 2.6.1 and its inclusion of `cffi 1.3.0`_, signals could be
could be delivered incorrectly or fail to be delivered during a delivered incorrectly or fail to be delivered during a blocking
blocking operation. (PyPy 2.5.0 includes CFFI 0.8.6 while 2.6.0 has operation. (PyPy 2.5.0 includes CFFI 0.8.6 while 2.6.0 has 1.1.0;
1.1.0; the necessary feature was added in `1.2.0`_ which is not the necessary feature was added in `1.2.0`_ which is not itself
itself directly present in any PyPy release.) directly present in any PyPy release.) CFFI 1.3.0 also allows using
the CFFI backend on CPython.
- Overall performance seems to be quite acceptable with newer versions - Overall performance seems to be quite acceptable with newer versions
of PyPy. The benchmarks distributed with gevent typically perform as of PyPy. The benchmarks distributed with gevent typically perform as
well or better on PyPy than on CPython. Things that are known or well or better on PyPy than on CPython at least on some platforms.
expected to be (relatively) slower under PyPy include the Things that are known or expected to be (relatively) slower under
:mod:`c-ares resolver <gevent.resolver_ares>` and PyPy include the :mod:`c-ares resolver <gevent.resolver_ares>` and
:class:`gevent.lock.Semaphore`. Whether or not these matter will :class:`gevent.lock.Semaphore`. Whether or not these matter will
depend on the workload of each application. depend on the workload of each application.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment