Commits

Armin Rigo committed 4144b92

Finally test the R_Container/FieldName optional arguments to
the barriers.

  • Participants
  • Parent commits 6cf5e84

Comments (0)

Files changed (1)

hack/stm/python/test_c2.py

         res = []
         for i in range(3):
             ptr = start
+            ptr_out_of = ()
             field = 'xy'[p < 0.5]
             while p >= 0.1:
                 print p
                 assert p < 1.0
                 p *= 2.0
-                ptr = cpu.DirectReadBarrier(ptr)
+                ptr = cpu.DirectReadBarrier(ptr, *ptr_out_of)
                 if p >= 1.0:
                     p -= 1.0
                     field = 'x'
                 if next is None:
                     ptr = cpu.WriteBarrierFromReadReady(ptr)
                     break
+                ptr_out_of = (ptr, field)
                 ptr = next
             else:
-                ptr = cpu.WriteBarrier(ptr)
+                ptr = cpu.WriteBarrier(ptr, *ptr_out_of)
             print p
             res.append(field.upper())
             p = 0.99 - p