Welcome to XDA

Search to go directly to your device's forum

Register an account

Unlock full posting privileges

Ask a question

No registration required
Post Reply

Odex or Deodex with ART?

OP razz1

19th August 2014, 09:27 PM   |  #1  
razz1's Avatar
OP Senior Member
Flag chicago
Thanks Meter: 726
 
652 posts
Join Date:Joined: Nov 2011
More
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?
20th August 2014, 03:27 AM   |  #2  
razz1's Avatar
OP Senior Member
Flag chicago
Thanks Meter: 726
 
652 posts
Join Date:Joined: Nov 2011
More
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.
20th August 2014, 06:05 AM   |  #3  
BadUsername's Avatar
Recognized Contributor
Thanks Meter: 806
 
1,594 posts
Join Date:Joined: Mar 2013
More
Quote:
Originally Posted by razz1

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.
The Following User Says Thank You to BadUsername For This Useful Post: [ View ]
21st August 2014, 05:09 AM   |  #4  
razz1's Avatar
OP Senior Member
Flag chicago
Thanks Meter: 726
 
652 posts
Join Date:Joined: Nov 2011
More
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.

3rd December 2014, 10:55 PM   |  #5  
Senior Member
Thanks Meter: 81
 
643 posts
Join Date:Joined: Aug 2013
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 by giaur; 3rd December 2014 at 10:58 PM.
Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes