mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
This class is meant to be thread safe. In fact, its headerdoc statement on thread safety even mentions this. All fields on the class are readonly except the child isolate preparer. This field is set during VM instantiated isolate initialization. The VM may launch multiple isolate in the same isolate group on at the same time (each on a VM backed thread pool thread). Attempting to set the field without synchronization is a data race. Fixes https://github.com/flutter/flutter/issues/49358 Fixes b/147798920