[pypy-commit] pypy default: kill some no longer needed indirection

cfbolz pypy.commits at gmail.com
Fri Feb 26 07:15:15 EST 2016


Author: Carl Friedrich Bolz <cfbolz at gmx.de>
Branch: 
Changeset: r82559:d9671adc681a
Date: 2016-02-26 13:14 +0100
http://bitbucket.org/pypy/pypy/changeset/d9671adc681a/

Log:	kill some no longer needed indirection

diff --git a/pypy/objspace/std/mapdict.py b/pypy/objspace/std/mapdict.py
--- a/pypy/objspace/std/mapdict.py
+++ b/pypy/objspace/std/mapdict.py
@@ -65,21 +65,8 @@
     def delete(self, obj, name, index):
         pass
 
+    @jit.elidable
     def find_map_attr(self, name, index):
-        if jit.we_are_jitted():
-            # hack for the jit:
-            # the _find_map_attr method is pure too, but its argument is never
-            # constant, because it is always a new tuple
-            return self._find_map_attr_jit_pure(name, index)
-        else:
-            return self._find_map_attr_indirection(name, index)
-
-    @jit.elidable
-    def _find_map_attr_jit_pure(self, name, index):
-        return self._find_map_attr_indirection(name, index)
-
-    @jit.dont_look_inside
-    def _find_map_attr_indirection(self, name, index):
         if (self.space.config.objspace.std.withmethodcache):
             return self._find_map_attr_cache(name, index)
         return self._find_map_attr(name, index)


More information about the pypy-commit mailing list