Debian Codegraph @

pypy/doc/release-2.3.0.rst

raw
1 =======================================
2 PyPy 2.3 - Terrestrial Arthropod Trap
3 =======================================
4
5 We're pleased to announce PyPy 2.3, which targets version 2.7.6 of the Python
6 language. This release updates the stdlib from 2.7.3, jumping directly to 2.7.6.
7
8 This release also contains several bugfixes and performance improvements,
9 many generated by real users finding corner cases our `TDD`_ methods missed.
10 `CFFI`_ has made it easier than ever to use existing C code with both cpython
11 and PyPy, easing the transition for packages like `cryptography`_, `Pillow`_
12 (Python Imaging Library [Fork]), a basic port of `pygame-cffi`_, and others.
13
14 PyPy can now be embedded in a hosting application, for instance inside `uWSGI`_
15
16 You can download the PyPy 2.3 release here:
17
18 https://pypy.org/download.html
19
20 We would like to thank our donors for the continued support of the PyPy
21 project, and for those who donate to our three sub-projects.
22 We showed quite a bit of progress
23 but we're slowly running out of funds.
24 Please consider donating more, or even better convince your employer to donate,
25 so we can finish those projects! The three sub-projects are:
26
27 * `Py3k`_ (supporting Python 3.x): the release PyPy3 2.2 is imminent.
28
29 * `STM`_ (software transactional memory): a preview will be released very soon,
30 once we fix a few bugs
31
32 * `NumPy`_ which is included in the PyPy 2.3 release. More details below.
33
34 .. _`Py3k`: https://pypy.org/py3donate.html
35 .. _`STM`: https://pypy.org/tmdonate2.html
36 .. _ `NumPy`: https://pypy.org/numpydonate.html
37 .. _`TDD`: https://doc.pypy.org/how-to-contribute.html
38 .. _`CFFI`: https://cffi.readthedocs.org
39 .. _`cryptography`: https://cryptography.io
40 .. _`Pillow`: https://pypi.python.org/pypi/Pillow/2.4.0
41 .. _`pygame-cffi`: https://github.com/CTPUG/pygame_cffi
42 .. _`uWSGI`: https://uwsgi-docs.readthedocs.org/en/latest/PyPy.html
43
44 What is PyPy?
45 =============
46
47 PyPy is a very compliant Python interpreter, almost a drop-in replacement for
48 CPython 2.7. It's fast (`pypy 2.3 and cpython 2.7.x`_ performance comparison;
49 note that cpython's speed has not changed since 2.7.2)
50 due to its integrated tracing JIT compiler.
51
52 This release supports x86 machines running Linux 32/64, Mac OS X 64, Windows,
53 and OpenBSD,
54 as well as newer ARM hardware (ARMv6 or ARMv7, with VFPv3) running Linux.
55
56 While we support 32 bit python on Windows, work on the native Windows 64
57 bit python is still stalling, we would welcome a volunteer
58 to `handle that`_.
59
60 .. _`pypy 2.3 and cpython 2.7.x`: https://speed.pypy.org
61 .. _`handle that`: https://doc.pypy.org/windows.html#what-is-missing-for-a-full-64-bit-translation
62
63 Highlights
64 ==========
65
66 Bugfixes
67 --------
68
69 Many issues were cleaned up after being reported by users to https://bugs.pypy.org or on IRC at #pypy. Note that we consider
70 performance slowdowns as bugs. Here is a summary of the user-facing changes;
71 for more information see `whats-new`_:
72
73 * The ARM port no longer crashes on unaligned memory access to floats and doubles,
74 and singlefloats are supported in the JIT.
75
76 * Generators are faster since they now skip unnecessary cleanup
77
78 * A first time contributor simplified JIT traces by adding integer bound
79 propagation in indexing and logical operations.
80
81 * Optimize consecutive dictionary lookups of the same key in a chain
82
83 * Our extensive pre-translation test suite now runs nightly on more platforms
84
85 * Fix issues with reimporting builtin modules
86
87 * Fix an RPython bug with loop-unrolling that appeared in the `HippyVM`_ PHP port
88
89 * Support for corner cases on objects with __int__ and __float__ methods
90
91 * Fix multithreaded support for gethostbyname_ex and gethostbyaddr
92
93 * Fix handling of tp_name for type objects
94
95 .. _`HippyVM`: https://www.hippyvm.com
96 .. _`whats-new`: https://doc.pypy.org/whatsnew-2.3.0.html
97
98
99 New Platforms and Features
100 --------------------------
101
102 * Support for OpenBSD
103
104 * Code cleanup: we continue to prune out old and unused code, and to refactor
105 large parts of the codebase. We have separated RPython from the PyPy python
106 interpreter, and RPython is seeing use in other dynamic language projects.
107
108 * Support for precompiled headers in the build process for MSVC
109
110 * Tweak support of errno in cpyext (the PyPy implementation of the capi)
111
112
113 NumPy
114 -----
115 NumPy support has been split into a builtin ``_numpy`` module and a
116 fork of the NumPy code base adapted to PyPy at
117 ``https://bitbucket.org/pypy/numpy``.
118 You need to install NumPy separately with a virtualenv:
119
120 ``pip install git+https://bitbucket.org/pypy/numpy.git``;
121
122 or directly:
123
124 ``git clone https://bitbucket.org/pypy/numpy.git``;
125 ``cd numpy``; ``pypy setup.py install``.
126
127 * NumPy support has been improved, many failures in indexing, dtypes,
128 and scalars were corrected. We are slowly approaching our goal of passing
129 the NumPy test suite. We still do not support object or unicode ndarrays.
130
131 * Speed of iteration in dot() is now within 1.5x of the NumPy c
132 implementation (without BLAS acceleration). Since the same array
133 iterator is used throughout the ``_numpy`` module, speed increases should
134 be apparent in all NumPy functionality.
135
136 * Most of the core functionality of nditer has been implemented.
137
138 * A cffi-based ``numpy.random`` module is available as a branch;
139 it will be merged soon after this release.
140
141 * Enhancements to the PyPy JIT were made to support virtualizing the raw_store/raw_load
142 memory operations used in NumPy arrays. Further work remains here in virtualizing the
143 alloc_raw_storage when possible. This will allow scalars to have storages but still be
144 virtualized when possible in loops.
145
146 Cheers
147
148 The PyPy Team
149