[pypy-svn] r53538 - pypy/branch/jit-hotpath/pypy/rpython/lltypesystem

arigo at codespeak.net arigo at codespeak.net
Mon Apr 7 20:07:40 CEST 2008


Author: arigo
Date: Mon Apr  7 20:07:39 2008
New Revision: 53538

Modified:
   pypy/branch/jit-hotpath/pypy/rpython/lltypesystem/lloperation.py
Log:
Drop the exception path if the operation cannot raise.


Modified: pypy/branch/jit-hotpath/pypy/rpython/lltypesystem/lloperation.py
==============================================================================
--- pypy/branch/jit-hotpath/pypy/rpython/lltypesystem/lloperation.py	(original)
+++ pypy/branch/jit-hotpath/pypy/rpython/lltypesystem/lloperation.py	Mon Apr  7 20:07:39 2008
@@ -122,7 +122,10 @@
     def specialize_call(self, hop):
         op = self.instance    # the LLOp object that was called
         args_v = [hop.inputarg(r, i+1) for i, r in enumerate(hop.args_r[1:])]
-        hop.exception_is_here()
+        if op.canraise:
+            hop.exception_is_here()
+        else:
+            hop.exception_cannot_occur()
         return hop.genop(op.opname, args_v, resulttype=hop.r_result.lowleveltype)
 
 



More information about the Pypy-commit mailing list