Reputation:
While updating android it will 'optimize' apps. This process takes quite some while. It takes so much time that I wonder if any binaries will be changed in order to improve performance. Does this change anything for developers? So my question is what happens when android does that?
Upvotes: 1
Views: 332
Reputation: 10131
The Android OS does not store apps as is after installation (i.e. 1 single APK file). An optimized version of the app is stored in the Dalvik cache - called the odex file.
If you have rooted your phone you will be able to view that partition and see many of your apps having related files there.
Coming back to your question, the initial boot is when the odex files are generated. And subsequently as applications are installed and launched. This is takes place when u update.
Read up more on http://www.xda-developers.com/
For a further reading, this article would be useful for understanding the concept of "odex" files:http://www.addictivetips.com/mobile/what-is-odex-and-deodex-in-android-complete-guide/
Upvotes: 1
Reputation: 33408
When an APK file is added to your Android system, it’s not actually stored that way. It’s converted to something called an “odex” file. The Wikipedia states that “dex” stands for Dalvik EXecutable, and “odex” stands for Optimized Dalvik EXecutable.
That's what it is doing when it says it says optimizing apps - converting them to odex. Generally happens when there is a system update. Read more here
Upvotes: 0
Reputation: 1006819
While updating android it will 'optimize' apps
Only on Android 5.0-6.0.
what happens when android does that?
The ART runtime is generating native instructions for most of the Java bytecode, through what is known as ahead-of-time (AOT) compilation.
Note that Android 7.0 will no longer apply AOT at install time, but rather will do so incrementally as time goes by.
Does this change anything for developers?
The AOT generally does not, though older JNI code sometimes has issues.
Upvotes: 1