react-native/Libraries
Frédéric Sagnes 4a3857ef1d Use JSStringCreateWithUTF8CString and skip NSString decoding when loading the bundle
Summary: public

Benchmarking our startup path has shown we spend a lot of time decoding strings (iPhone 4S / iPhone 5):

* reading a 2MB JS bundle: 35ms / 15ms
* decoding is to an `NSString`: 186ms / 78ms
* transforming that to a `JSString`: 29ms / 10ms

Instead of going through an `NSString` transformation, we generate a null-terminated bundle (0.1ms / 0.05ms to copy the data) and use `JSStringCreateWithUTF8CString` (121ms / 53ms) to generate the string. That makes decoding 70% faster.

Reviewed By: javache

Differential Revision: D2541140

fb-gh-sync-id: 09a016b8edfd46a9b62682c76705564d2024e75e
2015-10-16 08:11:25 -07:00
..
ART Refactor RCTUIManager 2015-08-06 15:49:35 -08:00
ActionSheetIOS App Extension support 2015-09-22 10:46:26 -07:00
AdSupport Text highlighting on iOS 2015-07-24 08:41:58 -08:00
Animated `isInteraction` option to keep InteractionManager unblocked 2015-10-15 09:22:33 -07:00
AppRegistry [React Native] Provide a way to get a list of registered apps in AppRegistry 2015-08-07 11:05:25 -08:00
AppStateIOS revert D2372548 to fix initial app state issue 2015-09-25 13:25:26 -07:00
BatchedBridge Adding jest tests to groups rn 2015-08-31 17:35:47 -08:00
CameraRoll RC Fix storyline cannot open bug (iOS 7) 2015-09-29 09:21:55 -07:00
Components Use RecyclerViewBackedScrollView in groups feed on Android. 2015-10-16 07:45:22 -07:00
CustomComponents Make removeClippedSubviews default to true on ListView/RecyclingListView 2015-10-13 08:06:26 -07:00
DebugComponentHierarchy [ReactNative] Send debug component ownership info in createView 2015-06-25 05:47:24 -08:00
Device
Devtools [Flow] Clean up react-native for Flow v0.15.0 2015-09-04 16:51:18 -08:00
Fetch Better feature detection for FormData/FileReader/Blob 2015-09-22 13:53:24 -07:00
Geolocation fix watchPosition keep updating location 2015-10-12 11:56:45 -07:00
Image Added RCTFileRequestHandler 2015-10-13 08:14:28 -07:00
Inspector [react-native] enable react devtools from JavascriptCore 2015-07-23 17:14:09 -08:00
Interaction InteractionManager: remove dev timeout warnings 2015-07-01 04:51:28 -08:00
JavaScriptAppEngine Fix 16 linter warnings in Examples/ 2015-10-16 04:03:23 -07:00
LayoutAnimation [ReactNative] Remove POPAnimation 2015-08-20 22:24:28 -07:00
LinkingIOS Add note for iOS9 url scheme changes 2015-10-12 08:04:24 -07:00
Modal Explanation of Modal's purpose in hybrid apps 2015-09-27 23:48:22 -07:00
NativeApp
Network Added RCTFileRequestHandler 2015-10-13 08:14:28 -07:00
Picker Fixed PickerIOS onChange event 2015-09-08 03:34:33 -08:00
Portal [RN] add clarifying Android-only comment to Portal 2015-08-31 11:10:45 -08:00
PushNotificationIOS Add documentation for making PushNotificationIOS events work, 2015-10-14 09:09:26 -07:00
QuickPerformanceLogger added QPL for main interactions 2015-09-29 22:25:23 -07:00
RCTTest Move SnapshotView to SnapshotViewIOS and create an unimplemented android version 2015-10-13 11:48:38 -07:00
RKBackendNode
ReactIOS Fix 16 linter warnings in Examples/ 2015-10-16 04:03:23 -07:00
ReactNative Add List of Common Cases to AttributePayload Benchmark 2015-10-09 14:31:23 -07:00
Sample
Settings Text highlighting on iOS 2015-07-24 08:41:58 -08:00
Storage Get back 100% in sync with fb codebase 2015-09-16 10:30:53 -07:00
StyleSheet Add deprecated transform props to View prop type definition. 2015-10-16 07:30:26 -07:00
Text Fix 16 linter warnings in Examples/ 2015-10-16 04:03:23 -07:00
Utilities Batch native method calls in 5ms increments 2015-10-13 08:03:41 -07:00
Vibration Text highlighting on iOS 2015-07-24 08:41:58 -08:00
WebSocket Use JSStringCreateWithUTF8CString and skip NSString decoding when loading the bundle 2015-10-16 08:11:25 -07:00
react-native Move SnapshotView to SnapshotViewIOS and create an unimplemented android version 2015-10-13 11:48:38 -07:00
vendor Move stuff out of vendor/react_contrib/ 2015-10-12 11:18:30 -07:00
Promise.js