-
Notifications
You must be signed in to change notification settings - Fork 59
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
Improve load time for NaCl module #10
Comments
I tried stripping the binary, but it didn't seem to have any effect. Not having any luck finding docs on how to speed up the load time. May have to resort to a preloading strategy. |
Here's the API for getting a callback as soon as the app is installed or updated: |
The PNaCl folks said that loading the module in onInstalled() isn't a bad strategy. I do worry about burning cycles for someone who may have the app installed but aren't actively using it, but maybe that's not a huge deal for as infrequently as it'd happen. |
One minor thing that would go a long way is showing progress. I believe there's a progress callback you can use: https://developers.google.com/native-client/dev/devguide/coding/progress-events |
Agreed. I had contemplated adding a progress indication of some sort, and am aware of that API. Since you mentioned it, I'll see about adding it next time I'm in the code. |
Progress bar added in SHA c6ae894. Still to do: Consider preloading the module on update. |
I've decided against loading the module on update. It goes against my grain to burn CPU for this, since some users may not actively use the app. It also causes the progress bar not to work the way it is currently implemented, and it just isn't worth wiring it all through. I hope that the Chrome folks make this more efficient in the future, and there are ways I can imagine they could. For now, I think the progress bar softens the blow sufficiently. |
Since the move to PNaCl, the NaCl module take a long time to load the first time after an update. This is likely due to the module being converted to the local architecture. This delay is a bit off-putting, and could be a major annoyance during periods of rapid iteration. See if there's a way to cut down the load time or hide it. Some ideas:
The text was updated successfully, but these errors were encountered: