react-native-macos/ReactCommon/cxxreact
Ramanpreet Nara bf0e516086 Instrument async method call batch preprocessing
Summary:
NativeModule async method calls are queued up on the JS side, and flushed to C++ on every Native -> JS call. Before we execute the batch of async NativeModule method calls, we convert it (a JS object) from a `jsi::Value` to a `folly::dynamic` object in `JSIExecutor::callNativeModules`. Then, in `JsToNativeBridge::callNativeModules`, we convert this `folly::dynamic` object into an `std::vector<MethodCall>`, before finally looping over these `MethodCall`s and invoking each NativeModule async method call.

The markers I'm adding in this diff measure this `jsi::Value -> folly::dynamic -> std::vector<MethodCall>` pre-processing.

Changelog: [Internal]

Reviewed By: PeteTheHeat

Differential Revision: D21435455

fbshipit-source-id: 4c5a9e2b73c1a2a49d7a8f224a0d30afe3a0c79c
2020-05-13 20:28:17 -07:00
..
tests Replace fbsource// with // in xplat/js/ files [1] 2020-03-25 21:55:47 -07:00
.clang-tidy The life-changing magic of clang-tidying up 2020-02-04 11:09:30 -08:00
Android.mk Instrument JS requires 2020-05-13 20:28:17 -07:00
BUCK Instrument JS requires 2020-05-13 20:28:17 -07:00
CxxModule.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
CxxNativeModule.cpp Revert D20464278: Make Lambda function called in NativeModule mutable to improve performance 2020-03-16 16:21:28 -07:00
CxxNativeModule.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
Instance.cpp Expose RuntimeExecutor on CatalystInstance (#28851) 2020-05-08 16:13:42 -07:00
Instance.h Expose RuntimeExecutor on CatalystInstance (#28851) 2020-05-08 16:13:42 -07:00
JSBigString.cpp Replace folly::make_unique with std::make_unique (#26730) 2019-10-22 12:21:41 -07:00
JSBigString.h Tidy up license headers [1/n] 2019-10-16 10:06:33 -07:00
JSBundleType.cpp Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
JSBundleType.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
JSDeltaBundleClient.cpp Resolve React-cxxreact warnings (#28047) 2020-02-12 23:49:15 -08:00
JSDeltaBundleClient.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
JSExecutor.cpp Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
JSExecutor.h Split loadApplicationScript into initializeRuntime and loadBundle (#27844) 2020-04-01 17:52:39 -07:00
JSIndexedRAMBundle.cpp Replace folly::make_unique with std::make_unique (#26730) 2019-10-22 12:21:41 -07:00
JSIndexedRAMBundle.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
JSModulesUnbundle.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
JsArgumentHelpers-inl.h Run clang-format and apply patches 2020-02-27 08:29:30 -08:00
JsArgumentHelpers.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
MessageQueueThread.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
MethodCall.cpp Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
MethodCall.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
ModuleRegistry.cpp Instrument JS requires 2020-05-13 20:28:17 -07:00
ModuleRegistry.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
NativeModule.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
NativeToJsBridge.cpp Instrument async method call batch preprocessing 2020-05-13 20:28:17 -07:00
NativeToJsBridge.h Expose RuntimeExecutor on CatalystInstance (#28851) 2020-05-08 16:13:42 -07:00
RAMBundleRegistry.cpp Replace folly::make_unique with std::make_unique (#26730) 2019-10-22 12:21:41 -07:00
RAMBundleRegistry.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
React-cxxreact.podspec Instrument JS requires 2020-05-13 20:28:17 -07:00
ReactMarker.cpp Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
ReactMarker.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
ReactNativeVersion.h Stamp React Native Version Into C++ Code (#28036) 2020-02-27 06:42:14 -08:00
RecoverableError.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
SampleCxxModule.cpp Replace folly::make_unique with std::make_unique (#26730) 2019-10-22 12:21:41 -07:00
SampleCxxModule.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
SharedProxyCxxModule.h Codemod: Clang-format for all files in `ReactCommon` directory 2020-02-25 19:52:27 -08:00
SystraceSection.h Remove __unused annotation from ConcreteSystraceSection ctor args 2019-11-19 10:51:59 -08:00
re_worker_requirements Sync worker requirement mismatches 2019-05-26 01:39:01 -07:00