c91e2eb567
Summary: This converts the existing JSEvaluateScript call for `require('<ModuleName>').<MethodName>.apply(null, <args>);` to native JSC C API methods which shaves off about 10-15% of invocation time on average, I used pretty primitive profiling methods to track the minimum, maximum and average invocation time so would appreciate any extra eyes on the performance. If the argument count is zero the method is invoked directly with no arguments, if the argument count is 1 it's invoked directly with just that argument. If there is more than 1 argument then apply is used and the arguments are passed as the second parameter. Ensured all existing tests pass and instruments leaks shows nothing is leaking. Closes https://github.com/facebook/react-native/pull/1037 Github Author: Robert Payne <robertpayne@me.com> Test Plan: Imported from GitHub, without a `Test Plan:` line. |
||
---|---|---|
.. | ||
RCTContextExecutor.h | ||
RCTContextExecutor.m | ||
RCTWebViewExecutor.h | ||
RCTWebViewExecutor.m |