-
Notifications
You must be signed in to change notification settings - Fork 661
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RN 0.63.1 + enableHermes -> very slow launch performances #318
Comments
Thanks for the report. It's easier to debug these sorts of issues with some code to look at - without it, we're in the dark regarding the actual problem. A few things to try:
|
@imranMnts any updates? Have you tried what @avp suggested (especially making sure you were in the release mode)? |
I have seen this as well. We use react-native-sodium and the decrypt function itself takes about 7s. Due to this (and maybe other packages hit by this issue), the startup time is about 15-20s (we have to load encrypted data into redux). After disabling Hermes, the startup time is about 4-7s. We are using RN 0.63.4 and testing on low end Android devices (these seem to be affected the most). |
Besides of what @avp had mentioned, there is also possibility that you are not using pre-compiled bytecode. You can check if the |
FWIW, startup time of 4-7s doesn't sound that great either. Perhaps the lesson here is that JavaScript, even with a JIT, is just not that suitable for high intensity computation like decryption. It would work much better if the decryption was implemented in C++. |
@Huxpro I double-checked and I'm sure I'm in release mode. Hermes version: 0.7.2 |
Thanks all I fixed the issue on my side. It was due to the bundle generated in the APK, it was in JS and to beneficiate from Hermes' improvements it should be bytecode. |
@imgraham thanks for reporting back! As I mentioned before, this is often the cause:
Would you mind sharing with us how did you find it and what was the improvements? |
@imranMnts how did you fix it ? |
we generated the bundle manually via I removed it and added
in my |
so manually creating bundle solve the issue? |
I also encountered this problem。 very very slow. |
I tried this solution, but it didn't solve, it was still very slow |
@CloudCityxx Did you unzip your apk to check if your bundle contains bytecode or js? (in assets folder) |
For anyone who stumbles upon this with RN 0.71.0 |
Bug Description
I recently updated RN version of my project from 0.59.10 to 0.63.1. It works properly, I didn't detect any issue but when I turn on Hermes to benefice its advantages, my app takes 2 times longer to be launched in release mode.
Versions:
Hermes version: 0.5.0
React Native version: 0.63.1
Android version: Android 8.0
Device: Samsung J3
Launch times (to see the first screen of the app):
If anyone has had to face this problem, your help is welcome 🙂
Thank you.
The text was updated successfully, but these errors were encountered: