[pypy-commit] pypy py3.6: merge default into py3.6
mattip
pypy.commits at gmail.com
Thu Dec 19 06:58:19 EST 2019
Author: Matti Picus <matti.picus at gmail.com>
Branch: py3.6
Changeset: r98327:513377efa4e8
Date: 2019-12-19 13:55 +0200
http://bitbucket.org/pypy/pypy/changeset/513377efa4e8/
Log: merge default into py3.6
diff --git a/pypy/doc/release-v7.3.0.rst b/pypy/doc/release-v7.3.0.rst
--- a/pypy/doc/release-v7.3.0.rst
+++ b/pypy/doc/release-v7.3.0.rst
@@ -138,6 +138,10 @@
* Overflow in RPython when converting ``2<<32`` into a ``Signed`` on 32-bit
platforms rather than automatically using a ``SignedLongLong``, require an
explicit ``r_int64()`` call instead
+* Fix multithread contention when creating an object in cffi (PyPy only)
+* Copy lib/* shared objects in portable builds when creating virtual
+ environments with virtualenv and venv
+* Potential fix in rare-case JIT optimizer (`issue 3128`_)
C-API (cpyext) and c-extensions
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -226,6 +230,7 @@
.. _`issue 3117`: https://bitbucket.com/pypy/pypy/issues/3117
.. _`issue 3119`: https://bitbucket.com/pypy/pypy/issues/3119
.. _`issue 3120`: https://bitbucket.com/pypy/pypy/issues/3120
+.. _`issue 3128`: https://bitbucket.com/pypy/pypy/issues/3120
.. _13312: https://bugs.python.org/issue13312
.. _13617: https://bugs.python.org/issue13617
diff --git a/rpython/jit/metainterp/optimizeopt/optimizer.py b/rpython/jit/metainterp/optimizeopt/optimizer.py
--- a/rpython/jit/metainterp/optimizeopt/optimizer.py
+++ b/rpython/jit/metainterp/optimizeopt/optimizer.py
@@ -683,7 +683,14 @@
elif constvalue == 1:
opnum = rop.GUARD_TRUE
else:
- raise AssertionError("uh?")
+ # Issue #3128: there might be rare cases where strange
+ # code is produced. That issue hits the assert from
+ # OptUnroll.inline_short_preamble's send_extra_operation().
+ # Better just disable this optimization than crash with
+ # an AssertionError here. Note also that such code might
+ # trigger an InvalidLoop to be raised later---so we must
+ # not crash here.
+ return op
newop = self.replace_op_with(op, opnum, [op.getarg(0)], descr)
return newop
return op
diff --git a/rpython/jit/metainterp/optimizeopt/test/test_optimizeopt.py b/rpython/jit/metainterp/optimizeopt/test/test_optimizeopt.py
--- a/rpython/jit/metainterp/optimizeopt/test/test_optimizeopt.py
+++ b/rpython/jit/metainterp/optimizeopt/test/test_optimizeopt.py
@@ -698,6 +698,15 @@
"""
self.optimize_loop(ops, expected, preamble)
+ def test_guard_value_on_boolean_but_not_zero_or_one(self):
+ ops = """
+ [i]
+ i1 = int_lt(i, 3)
+ guard_value(i1, -1) [i]
+ jump(i)
+ """
+ py.test.raises(InvalidLoop, self.optimize_loop, ops, ops, ops)
+
def test_int_is_true_of_bool(self):
ops = """
[i0, i1]
More information about the pypy-commit
mailing list