Odex or Deodex with ART?

Search This thread

razz1

Senior Member
Nov 3, 2011
842
1,013
chicago
So I'm running ART on a deodexed rom and was thinking of re-odexing sys apps and framework. From what I understand is ART converts Deodexed and Odexed files differently. So what would be the better option? Anybody really knowledgeable on ART?
 

razz1

Senior Member
Nov 3, 2011
842
1,013
chicago
Well it looks like I may not get an answer but I did some real world testing along with some benchmarks on CM11 and can say without a doubt that ART converts odex better. Why? Not really sure. I don't have the knowledge or the time to really dig into this but an odexed system will still provide a performance improvement thru ART.
If anyone has any insight on the technical reasons as to why this is then please post. It would be interesting.
 

BadUsername

Senior Member
Mar 20, 2013
1,833
960
Well it looks like I may not get an answer but I did some real world testing along with some benchmarks on CM11 and can say without a doubt that ART converts odex better. Why? Not really sure. I don't have the knowledge or the time to really dig into this but an odexed system will still provide a performance improvement thru ART.
If anyone has any insight on the technical reasons as to why this is then please post. It would be interesting.
ART works significantly better because it cuts out the middle man dalvik creates. I read this a while ago so I might not be exactly right, but dalvik uses the dalvik cache to store app information, which in turn opens a second file to initiate the app to open. Adds a delay.

ART is specifically written for Android, while dalvik was originally created for much less of a demanding app environment. ART basically just uses 1 file to control an app, which cuts loading time down and the way apps run. It's just much more efficient.

I wouldn't expect odexing or deodexing to make much of a difference in this scenario.
 

razz1

Senior Member
Nov 3, 2011
842
1,013
chicago
Well I will say this. After a nice look at a logcat today I found errors of ART trying to identify an odex file (ELF Magic). This pertains to all odex! Just thought I would throw this out there if anyone is interested.

4516481e21f23c4e929b0b18464dc8e5.jpg
 

giaur

Senior Member
Aug 27, 2013
4,152
1,197
This is because ART is looking for compiled native ELF executable, not dalvik runtime. It's completly different format, bacause ELF is java bytecode compiled to native (similar as native .exe on Windows) and ODEX is not. ODEX is compiled as dalvik bytecode that still runs via dalvik VM, not natively.

You should not use .odex on ART.
 
Last edited:

Top Liked Posts

  • There are no posts matching your filters.
  • 2
    Well it looks like I may not get an answer but I did some real world testing along with some benchmarks on CM11 and can say without a doubt that ART converts odex better. Why? Not really sure. I don't have the knowledge or the time to really dig into this but an odexed system will still provide a performance improvement thru ART.
    If anyone has any insight on the technical reasons as to why this is then please post. It would be interesting.
    ART works significantly better because it cuts out the middle man dalvik creates. I read this a while ago so I might not be exactly right, but dalvik uses the dalvik cache to store app information, which in turn opens a second file to initiate the app to open. Adds a delay.

    ART is specifically written for Android, while dalvik was originally created for much less of a demanding app environment. ART basically just uses 1 file to control an app, which cuts loading time down and the way apps run. It's just much more efficient.

    I wouldn't expect odexing or deodexing to make much of a difference in this scenario.