[pypy-commit] pypy concurrent-marksweep: Add the tests to test_transformed_gc. Not passing so far, of course.

arigo noreply at buildbot.pypy.org
Sat Oct 8 10:25:56 CEST 2011


Author: Armin Rigo <arigo at tunes.org>
Branch: concurrent-marksweep
Changeset: r47871:d8e46aa55083
Date: 2011-10-07 18:20 +0200
http://bitbucket.org/pypy/pypy/changeset/d8e46aa55083/

Log:	Add the tests to test_transformed_gc. Not passing so far, of
	course.

diff --git a/pypy/config/translationoption.py b/pypy/config/translationoption.py
--- a/pypy/config/translationoption.py
+++ b/pypy/config/translationoption.py
@@ -58,7 +58,8 @@
     # gc
     ChoiceOption("gc", "Garbage Collection Strategy",
                  ["boehm", "ref", "marksweep", "semispace", "statistics",
-                  "generation", "hybrid", "markcompact", "minimark", "none"],
+                  "generation", "hybrid", "markcompact", "minimark",
+                  "concurrentms", "none"],
                   "ref", requires={
                      "ref": [("translation.rweakref", False), # XXX
                              ("translation.gctransformer", "ref")],
@@ -73,6 +74,7 @@
                                ("translation.continuation", False)],  # breaks
                      "markcompact": [("translation.gctransformer", "framework")],
                      "minimark": [("translation.gctransformer", "framework")],
+                     "concurrentms": [("translation.gctransformer", "framework")],
                      },
                   cmdline="--gc"),
     ChoiceOption("gctransformer", "GC transformer that is used - internal",
diff --git a/pypy/rpython/memory/gc/base.py b/pypy/rpython/memory/gc/base.py
--- a/pypy/rpython/memory/gc/base.py
+++ b/pypy/rpython/memory/gc/base.py
@@ -435,6 +435,7 @@
                "hybrid": "hybrid.HybridGC",
                "markcompact" : "markcompact.MarkCompactGC",
                "minimark" : "minimark.MiniMarkGC",
+               "concurrentms": "concurrentms.MostlyConcurrentMarkSweepGC",
                }
     try:
         modulename, classname = classes[config.translation.gc].split('.')
diff --git a/pypy/rpython/memory/test/test_gc.py b/pypy/rpython/memory/test/test_gc.py
--- a/pypy/rpython/memory/test/test_gc.py
+++ b/pypy/rpython/memory/test/test_gc.py
@@ -927,7 +927,7 @@
 class TestMiniMarkGCCardMarking(TestMiniMarkGC):
     GC_PARAMS = {'card_page_indices': 4}
 
-class TestMostlyConcurrentMarkSweepGC(TestMiniMarkGC):
+class TestMostlyConcurrentMarkSweepGC(GCTest):
     from pypy.rpython.memory.gc.concurrentms \
             import MostlyConcurrentMarkSweepGC as GCClass
 
@@ -935,3 +935,15 @@
         py.test.skip("in-progress")
     def test_from_objwithfinalizer_to_youngobj(self):
         py.test.skip("in-progress")
+    def test_finalizer(self):
+        py.test.skip("in-progress")
+    def test_finalizer_calls_malloc(self):
+        py.test.skip("in-progress")
+    def test_finalizer_calls_collect(self):
+        py.test.skip("in-progress")
+    def test_finalizer_resurrects(self):
+        py.test.skip("in-progress")
+    def test_weakref(self):
+        py.test.skip("in-progress")
+    def test_weakref_to_object_with_finalizer(self):
+        py.test.skip("in-progress")
diff --git a/pypy/rpython/memory/test/test_transformed_gc.py b/pypy/rpython/memory/test/test_transformed_gc.py
--- a/pypy/rpython/memory/test/test_transformed_gc.py
+++ b/pypy/rpython/memory/test/test_transformed_gc.py
@@ -1415,3 +1415,14 @@
             GC_PARAMS = {'space_size': 4096*WORD,
                          'translated_to_c': False}
             root_stack_depth = 200
+
+
+class TestMostlyConcurrentMarkSweepGC(GenericGCTests):
+    gcname = "concurrentms"
+    class gcpolicy(gc.FrameworkGcPolicy):
+        class transformerclass(framework.FrameworkGCTransformer):
+            from pypy.rpython.memory.gc.concurrentms \
+                    import MostlyConcurrentMarkSweepGC as GCClass
+            GC_PARAMS = {'page_size': 128*WORD,
+                         'translated_to_c': False}
+            root_stack_depth = 200


More information about the pypy-commit mailing list