[pypy-svn] pypy default: Fix tests that were affecting by translating x*2 into x << 1.

alex_gaynor commits-noreply at bitbucket.org
Wed Jan 12 07:43:23 CET 2011


Author: Alex Gaynor <alex.gaynor at gmail.com>
Branch: 
Changeset: r40617:2735eee58ca2
Date: 2011-01-12 00:43 -0600
http://bitbucket.org/pypy/pypy/changeset/2735eee58ca2/

Log:	Fix tests that were affecting by translating x*2 into x << 1.

diff --git a/pypy/jit/metainterp/test/test_basic.py b/pypy/jit/metainterp/test/test_basic.py
--- a/pypy/jit/metainterp/test/test_basic.py
+++ b/pypy/jit/metainterp/test/test_basic.py
@@ -342,7 +342,7 @@
         self.check_loop_count(1)
         self.check_loops({'guard_true': 1,
                           'int_add': 2, 'int_sub': 1, 'int_gt': 1,
-                          'int_mul': 1,
+                          'int_lshift': 1,
                           'jump': 1})
 
     def test_loop_invariant_mul_bridge1(self):

diff --git a/pypy/jit/metainterp/test/test_send.py b/pypy/jit/metainterp/test/test_send.py
--- a/pypy/jit/metainterp/test/test_send.py
+++ b/pypy/jit/metainterp/test/test_send.py
@@ -292,7 +292,7 @@
         # However, this doesn't match the initial value of 'w'.
         # XXX This not completely easy to check...
         self.check_loop_count(1)
-        self.check_loops(int_add=0, int_mul=1, guard_class=0,
+        self.check_loops(int_add=0, int_lshift=1, guard_class=0,
                          new_with_vtable=0, new=0)
 
     def test_indirect_call_unknown_object_1(self):


More information about the Pypy-commit mailing list