Revision: 18233
Author:   [email protected]
Date:     Tue Dec  3 13:12:52 2013 UTC
Log: Tests that make a stack allocated persistent weak and rely on gc need to force gc

Otherwise, if during a fuzzer test incremental marking is running, we'll
crash in the weak callback

BUG=none
[email protected]
LOG=n

Review URL: https://codereview.chromium.org/101843002
http://code.google.com/p/v8/source/detail?r=18233

Modified:
 /branches/bleeding_edge/test/cctest/test-api.cc

=======================================
--- /branches/bleeding_edge/test/cctest/test-api.cc Tue Dec 3 10:40:13 2013 UTC +++ /branches/bleeding_edge/test/cctest/test-api.cc Tue Dec 3 13:12:52 2013 UTC
@@ -13153,7 +13153,7 @@
   // weak callback of the first handle would be able to 'reallocate' it.
   handle1.SetWeak(&handle1, NewPersistentHandleCallback);
   handle2.Reset();
-  CcTest::heap()->CollectAllGarbage(i::Heap::kNoGCFlags);
+  CcTest::heap()->CollectAllGarbage(i::Heap::kAbortIncrementalMarkingMask);
 }


@@ -13179,7 +13179,7 @@
   }
   handle1.SetWeak(&handle1, DisposeAndForceGcCallback);
   to_be_disposed.Reset(isolate, handle2);
-  CcTest::heap()->CollectAllGarbage(i::Heap::kNoGCFlags);
+  CcTest::heap()->CollectAllGarbage(i::Heap::kAbortIncrementalMarkingMask);
 }

 void DisposingCallback(
@@ -13208,7 +13208,7 @@
   }
   handle2.SetWeak(&handle2, DisposingCallback);
   handle3.SetWeak(&handle3, HandleCreatingCallback);
-  CcTest::heap()->CollectAllGarbage(i::Heap::kNoGCFlags);
+  CcTest::heap()->CollectAllGarbage(i::Heap::kAbortIncrementalMarkingMask);
 }


--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to