Replace EventDispatcherImpl with LockFreeEventDispatcherImpl

Summary:
EventDispatcherImpl uses synchronized blocks all over to make it thread-safe. I'm concerned about the perf implications of this and creating contention between JS and UI threads.

This is locked behind a feature flag.

Enabled only for Fabric in StaticViewConfig mode, and a feature flag, for now.

Changelog: [Internal]

Reviewed By: mdvacca

Differential Revision: D28591331

fbshipit-source-id: ea8f93a2e1343ce37fa78690dcb62fe03594120f
This commit is contained in:
Joshua Gross
2021-05-21 17:22:41 -07:00
committed by Facebook GitHub Bot
parent a2ab3fccd0
commit 0510821170
3 changed files with 381 additions and 1 deletions
@@ -97,6 +97,8 @@ public class ReactFeatureFlags {
/** Enables Fabric for LogBox */
public static boolean enableFabricInLogBox = false;
public static boolean enableLockFreeEventDispatcher = false;
//
// ScrollView C++ UpdateState vs onScroll race fixes
//