[pypy-svn] r55238 - in pypy/branch/oo-jit/pypy/jit/codegen: cli cli/test i386/test llvm/test
antocuni at codespeak.net
antocuni at codespeak.net
Mon May 26 10:16:49 CEST 2008
Author: antocuni
Date: Mon May 26 10:16:47 2008
New Revision: 55238
Added:
pypy/branch/oo-jit/pypy/jit/codegen/cli/test/__init__.py (contents, props changed)
pypy/branch/oo-jit/pypy/jit/codegen/cli/test/test_promotion.py (contents, props changed)
Modified:
pypy/branch/oo-jit/pypy/jit/codegen/cli/operation.py
pypy/branch/oo-jit/pypy/jit/codegen/cli/rgenop.py
pypy/branch/oo-jit/pypy/jit/codegen/cli/test/test_interpreter.py
pypy/branch/oo-jit/pypy/jit/codegen/i386/test/test_genc_promotion.py
pypy/branch/oo-jit/pypy/jit/codegen/llvm/test/test_genc_promotion.py
Log:
"port" promotion tests to cli (they are all skipped so far)
Modified: pypy/branch/oo-jit/pypy/jit/codegen/cli/operation.py
==============================================================================
--- pypy/branch/oo-jit/pypy/jit/codegen/cli/operation.py (original)
+++ pypy/branch/oo-jit/pypy/jit/codegen/cli/operation.py Mon May 26 10:16:47 2008
@@ -169,7 +169,7 @@
self.fieldinfo = clitype.GetField(fieldname)
def restype(self):
- return self.fieldinfo.FieldType
+ return self.fieldinfo.get_FieldType()
def emit(self):
self.gv_obj.load(self.builder)
Modified: pypy/branch/oo-jit/pypy/jit/codegen/cli/rgenop.py
==============================================================================
--- pypy/branch/oo-jit/pypy/jit/codegen/cli/rgenop.py (original)
+++ pypy/branch/oo-jit/pypy/jit/codegen/cli/rgenop.py Mon May 26 10:16:47 2008
@@ -261,6 +261,15 @@
return SigToken(args, res, funcclass)
@staticmethod
+ def erasedType(T):
+ if isinstance(T, lltype.Primitive):
+ return lltype.Signed
+ elif isinstance(T, ootype.OOType):
+ return ootype.Object
+ else:
+ assert 0, "XXX not implemented"
+
+ @staticmethod
@specialize.memo()
def methToken(TYPE, methname):
return methname #XXX
Added: pypy/branch/oo-jit/pypy/jit/codegen/cli/test/__init__.py
==============================================================================
Modified: pypy/branch/oo-jit/pypy/jit/codegen/cli/test/test_interpreter.py
==============================================================================
--- pypy/branch/oo-jit/pypy/jit/codegen/cli/test/test_interpreter.py (original)
+++ pypy/branch/oo-jit/pypy/jit/codegen/cli/test/test_interpreter.py Mon May 26 10:16:47 2008
@@ -3,12 +3,9 @@
from pypy.jit.codegen.dump.rgenop import RDumpGenOp
from pypy.jit.rainbow.test.test_interpreter import TestOOType as RainbowTest
-class TestRainbowCli(RainbowTest):
+class CliMixin(object):
RGenOp = RCliGenOp
- # for the individual tests see
- # ====> ../../../rainbow/test/test_interpreter.py
-
def _invoke(self, generated, residualargs):
# mono sucks; if we call the generated function directly,
@@ -34,6 +31,12 @@
def check_insns(self, expected=None, **counts):
"Cannot check instructions in the generated assembler."
+class TestRainbowCli(CliMixin, RainbowTest):
+
+ # for the individual tests see
+ # ====> ../../../rainbow/test/test_interpreter.py
+
+
def test_simple_opt_const_propagation1(self):
py.test.skip('mono crash')
Added: pypy/branch/oo-jit/pypy/jit/codegen/cli/test/test_promotion.py
==============================================================================
--- (empty file)
+++ pypy/branch/oo-jit/pypy/jit/codegen/cli/test/test_promotion.py Mon May 26 10:16:47 2008
@@ -0,0 +1,33 @@
+import py
+from pypy.jit.codegen.cli.test.test_interpreter import CliMixin
+from pypy.jit.rainbow.test.test_promotion import TestOOType as PromotionTest
+
+class TestPromotionCli(CliMixin, PromotionTest):
+
+ # for the individual tests see
+ # ====> ../../../rainbow/test/test_promotion.py
+
+ def skip(self):
+ py.test.skip('in progress')
+
+ test_simple_promotion = skip
+ test_many_promotions = skip
+ test_promote_inside_call = skip
+ test_promote_inside_call2 = skip
+ test_two_promotions = skip
+ test_mixed_merges = skip
+ test_green_across_global_mp = skip
+ test_promote_bug_1 = skip
+ test_exception_after_promotion = skip
+ test_promote_in_yellow_call = skip
+ test_more_promote_in_yellow_call = skip
+ test_two_promotions_in_call = skip
+ test_more_promotes = skip
+ test_raise_result_mixup_some_more = skip
+ test_raise_result_mixup = skip
+ test_remembers_across_mp = skip
+ test_promote_after_yellow_call = skip
+ test_virtual_list_copy = skip
+ test_vstruct_unfreeze = skip
+ test_promote_after_call = skip
+ test_merge_then_promote = skip
Modified: pypy/branch/oo-jit/pypy/jit/codegen/i386/test/test_genc_promotion.py
==============================================================================
--- pypy/branch/oo-jit/pypy/jit/codegen/i386/test/test_genc_promotion.py (original)
+++ pypy/branch/oo-jit/pypy/jit/codegen/i386/test/test_genc_promotion.py Mon May 26 10:16:47 2008
@@ -4,7 +4,7 @@
from pypy.jit.codegen.i386.test.test_genc_ts import I386TimeshiftingTestMixin
class TestPromotion(I386TimeshiftingTestMixin,
- test_promotion.TestPromotion):
+ test_promotion.TestLLType):
# for the individual tests see
# ====> ../../../timeshifter/test/test_promotion.py
Modified: pypy/branch/oo-jit/pypy/jit/codegen/llvm/test/test_genc_promotion.py
==============================================================================
--- pypy/branch/oo-jit/pypy/jit/codegen/llvm/test/test_genc_promotion.py (original)
+++ pypy/branch/oo-jit/pypy/jit/codegen/llvm/test/test_genc_promotion.py Mon May 26 10:16:47 2008
@@ -5,7 +5,7 @@
py.test.skip("WIP")
class TestPromotion(LLVMTimeshiftingTestMixin,
- test_promotion.TestPromotion):
+ test_promotion.TestLLType):
# for the individual tests see
# ====> ../../../timeshifter/test/test_promotion.py
More information about the Pypy-commit
mailing list