[pypy-commit] pypy ppc-jit-backend: add method to branch and link to absolute address

hager noreply at buildbot.pypy.org
Tue Feb 28 14:08:02 CET 2012


Author: hager <sven.hager at uni-duesseldorf.de>
Branch: ppc-jit-backend
Changeset: r52970:758b09fb2f1f
Date: 2012-02-27 17:27 +0100
http://bitbucket.org/pypy/pypy/changeset/758b09fb2f1f/

Log:	add method to branch and link to absolute address

diff --git a/pypy/jit/backend/ppc/codebuilder.py b/pypy/jit/backend/ppc/codebuilder.py
--- a/pypy/jit/backend/ppc/codebuilder.py
+++ b/pypy/jit/backend/ppc/codebuilder.py
@@ -1035,6 +1035,12 @@
             self.trap()
         self.bctr()
 
+    def bl_abs(self, address):
+        with scratch_reg(self):
+            self.load_imm(r.SCRATCH, address)
+            self.mtctr(r.SCRATCH.value)
+        self.bctrl()
+
     def call(self, address):
         """ do a call to an absolute address
         """


More information about the pypy-commit mailing list