• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

ART vs Dalvik

Madbat

Android Expert
There are a lot interesting ideas regarding this topic but there's a huge point that is disregarded. Without ART, android apps even some system apps are available as interpreted code rather than compiled code. Interpreted code is compiled at runtime and is being interpreted on the fly hence JIT. This affects the performance throughout the app lifecycle and not only during launch time. Scrolling, transistions, fluid motions, etc are all affected. This explains why iOS or WP run apps faster even on slower hardware. This is because they run native machine code and not interpreted code like Android. WP and iOS has no middle ground between apps and machine. Google on the other hand had to tackle issue of multiple hardware configurations for each device. Knowing that, interpreted code was the obvious solution. Now with ART, interpreted code will be compiled upon installation making the app on android native to the system. Apps won't run on a virtual machine anymore. This will save CPU power, that will impact positively and dramatically on the battery life, which in the end will make applications run way faster. Think about ART as a compiler for interpreted code. The more optimized the compiler, the faster and more optimized the application will be. ART is still in early stages, I already see a good improvement in fluidity and smoothness of transitions whether it's in launchers or apps especially chrome, Facebook, and Facebook messenger. (No its not placebo as I tried both environments on a factory reset nexus 4. Facebook messenger chat head never lagged once on ART but clearly lags when its popped on Dalvik VM. Don't get me started on Chrome :)). Hope this helps clearing out some ideas regarding ART.
Edit: Today
 
I haven't tried switching mine to art yet. I should give it a try.
What's the major advantage/difference?
 
It is smoother. Nice word choice. Agreed. Since the apps are compiled ahead of time for your particular device, the theory is that they will load faster and run smoother. It also is supposed to be less demanding on CPU, hence possibly better battery life as well. Keep in mind not all apps will run on ART. On dalvik apps are compiled when you launch them. ART is very young right now so not perfect.
 
With regards to switching to art, does it reset your apps/device/home screen settings etc. in any way when switching over?
 
With regards to switching to art, does it reset your apps/device/home screen settings etc. in any way when switching over?

Nope. Takes a while to switch (about 20 min depending how many apps) and you can switch right back if you want.
 
So how would one do this switch were one so inclined? Or have I removed myself from the list of people who should perhaps try it by asking? :p
 
So how would one do this switch were one so inclined? Or have I removed myself from the list of people who should perhaps try it by asking? :p

Anyone can do it. Its in developer options. To unlock developer options go to settings->about device and tap build number like 7 times I think. Then hit back and now developer options should be near the bottom of settings. Go into developer options and look for runtime. Tap it then select ART then reboot. It will take a few minutes to reboot, then you will be on ART. To go back, go to runtime again and select dalvik. :cool:
 
I did it. Haven't noticed any issues. I did find it turned off after sitting all night on the wireless charger. It may have done this once before. No biggie.
 
Just turned it on, but the nexus was already fast, and I'm not sure I am seeing much difference !

I've bounced back and forth between them and can't really see a difference in performance. Went back to Dalvik because a particular app I use doesn't work under ART.
 
Performance difference is subtle, mostly app opening speed. CPU is a little less stressed. Its still young, it will get better the further it gets developed. Ultimately (when it completely developed) when you install an app it will be compiled for your particular CPU and device, reducing lag when opening apps.
 
Performance difference is subtle, mostly app opening speed. CPU is a little less stressed. Its still young, it will get better the further it gets developed. Ultimately (when it completely developed) when you install an app it will be compiled for your particular CPU and device, reducing lag when opening apps.

And the app compatibility issues will go away.
 
I was surprised that one of those incompatibilities was with play store. It failed to install a new app because it could not pop up the permissions accept dialog. Back to Dalvik and it works fine again.
 
Play store worked fine for me. But that's why its not on by default, not fully stable. No telling what factors contributed to it breaking play store for you.
 
I've bounced back and forth between them and can't really see a difference in performance. Went back to Dalvik because a particular app I use doesn't work under ART.

Same, not really seeing much difference between them. Hopefully we will get major improvements in the next Android update because I don't think it's worth using ART right now.
 
Back
Top Bottom