[pypy-commit] pypy stm-gc: Fix the test.

arigo noreply at buildbot.pypy.org
Sat Apr 21 10:26:18 CEST 2012


Author: Armin Rigo <arigo at tunes.org>
Branch: stm-gc
Changeset: r54605:bc9b1f1e564d
Date: 2012-04-21 10:21 +0200
http://bitbucket.org/pypy/pypy/changeset/bc9b1f1e564d/

Log:	Fix the test.

diff --git a/pypy/rpython/memory/gctransform/stmframework.py b/pypy/rpython/memory/gctransform/stmframework.py
--- a/pypy/rpython/memory/gctransform/stmframework.py
+++ b/pypy/rpython/memory/gctransform/stmframework.py
@@ -70,12 +70,16 @@
         hop.genop("direct_call", [self.teardown_thread_ptr, self.c_const_gc])
 
     def gct_stm_enter_transactional_mode(self, hop):
+        livevars = self.push_roots(hop)
         hop.genop("direct_call", [self.stm_enter_transactional_mode_ptr,
                                   self.c_const_gc])
+        self.pop_roots(hop, livevars)
 
     def gct_stm_leave_transactional_mode(self, hop):
+        livevars = self.push_roots(hop)
         hop.genop("direct_call", [self.stm_leave_transactional_mode_ptr,
                                   self.c_const_gc])
+        self.pop_roots(hop, livevars)
 
     def gct_stm_writebarrier(self, hop):
         op = hop.spaceop
@@ -96,10 +100,14 @@
         hop.genop('cast_adr_to_ptr', [v_globaladr], resultvar=op.result)
 
     def gct_stm_start_transaction(self, hop):
+        livevars = self.push_roots(hop)
         hop.genop("direct_call", [self.stm_start_ptr, self.c_const_gc])
+        self.pop_roots(hop, livevars)
 
     def gct_stm_commit_transaction(self, hop):
+        livevars = self.push_roots(hop)
         hop.genop("direct_call", [self.stm_commit_ptr, self.c_const_gc])
+        self.pop_roots(hop, livevars)
 
 
 class StmShadowStackRootWalker(BaseRootWalker):


More information about the pypy-commit mailing list