Fix race in AllocEntrypointsInstrumented
We were using the quick_alloc_entry_points_instrumentation_counter_, this counter is updated before the threads are suspended. The allocator could come out of a suspend point, see that threads are supposedly still no instrumented, continue the allocation, then suddenly quick_alloc_entry_points_instrumentation_counter_ becomes 1 and alloc_tracking_enabled_ becomes true resulting in a failing DCHECK. The fix is to add a boolean that is updated only when the threads are suspended. Bug: 27506909 Change-Id: Ic3c6716d2af9c00189ce9271f7a2825b03cdd8a0
Loading
Please sign in to comment