Dalvik’s future replacement debuts in Android 4.4 KitKat, currently an experimental feature

November 6, 2013

    Android 4.4 KitKat

    With Android 4.4 KitKat we have already seen quite a few new features including a modernized phone dialer, improved Google Now integration and faster multi-tasking. What you might not know is that deep inside KitKat there is also a hidden experimental feature that could forever change Android as we know it.

    The new ‘feature’ goes by the name ART, as in Android Runtime. The goal of ART is to replace the aging Dalvik runtime, and is the fruits of over two years of work from Google.

    While the first whispers about ART residing in KitKat go back to as early as last week, earlier today Android Police dug in a bit deeper to bring us a bit more information on what to expect and how to even test out the new runtime for yourself. Although ART isn’t turned on by default in Android 4.4 KitKat, it can be found within Developer options and can easily be switched on.

    Of course there’s a reason Google has yet to make ART the default runtime. Right now, ART is still very much a work in progress, and Google warns that using it can cause system instability and can risk breaking apps.

    So what makes ART potentially better than Dalvik?

    With Dalvik, each and every time you open an app, a bunch of code needs to be compiled using the Just-in-Time compiler. This method takes a pretty hefty toll on your smartphone, as the process itself isn’t particularly efficient.

    That’s where ART comes in. Instead of doing all this compiling work each and every time you open an app, ART uses a Ahead-of-Time compilation method that pre-compiles bytecode into machine language from the moment that you first install an app.

    Because ART no longer needs to run all that interpreted code when starting up an app, the end result is that apps will launch quicker and will run more smoothly. While ART will likely get even better as Google continues to work on it, in the current KitKat build, ART reportedly was able to cut down execution times in half for nearly every application thrown at it.

    With apps launching more efficiently, less stress is put on our mobile device’s processors and other components, and this leads to not only a better Android experience but less power usage as well, meaning that ART could indirectly help out by extending battery life.

    On the downside, the AOT method takes up a bit more space when installing apps and results in a much longer installation time for more complex apps — though it sounds like the benefits far outweigh these minor annoyances.

    If you are currently running Android 4.4 KitKat, testing out ART is as easy as going to Settings> Developer Options> Select Runtime.

    Keep in mind that ART isn’t fully ready for primetime just yet, so test it at your own risk. It’s also worth noting that if you are using a ROM, there is a chance that the gapps package could cause serious crashing issues — so again, proceed at your own risk.

    Looking ahead

    While it’s nice to see Google allowing developers to test out ART on Android 4.4 KitKat, the bigger takeaway is that the days of Dalvik are almost over and we could soon be looking at a new era for Android, one where some of the so-called app/UI lag is behind us for good.

    When can we expect ART to arrive as the default in Android? While we’d love to say something definitive like “you’ll see it in Android 4.5″, the honest answer is that it will arrive when it’s ready. That said, if Google has enough confidence to let folks take it for a spin in KitKat, the official transition to ART might not be terribly far off.

    What do you think of ART based on what we currently know? Excited about the idea of seeing a Dalvik-free Android future?


    • geel

      wow, it’s cool. i hope new versions of Android with ART will be compatible with smartphones in sale now.

    • Jivester

      Hey Andrew Grush, I tried it on my N5 and noticed a substantial difference in the opening of apps. I would love it if you folks at AA would do a side by side comparison video of Dalvik vs, ART. That way I would know if I took the placebo pill or not :)

      • Dan

        Hey Jivester,

        Why don’t you make a comparison video?

        I’m interested in this as well and would be greatly appreciative! I am sure others would be too as the majority of us do not have access to 4.4 or a N5 yet.

        • Jivester

          I only have one N5 which makes comparison difficult. I was hoping the geeks at AA would have a couple lying around to do it with :)

          • Seth Forbus

            You just record the same N5 twice and you are good. I’ll try it on my roomates phone later.

      • Jivester

        Is it possible that the camera app is working faster as well now?


        did you notice improvements in battery life

        • Jivester

          Only had it half a day before changing.

          • KRIS THOMAS

            You mean battery lasted only half a day

            • Jivester

              No, sorry. I only had it half a day before switching to ART so I can’t compare.

            • KRIS THOMAS

              oh okay

    • Dan

      “On the downside, the AHT method takes up a bit more space when installing apps and results in a much longer installation time for more complex apps — though it sounds like the benefits far outweigh these minor annoyances.”

      AHT should say ART.
      Great read, Andrew – don’t forget to proof-read your work before publishing!

      I’m interested to see if this will in fact make a noticeable difference once I get my hands on 4.4.

      • Javier Rapoport

        not really, AHT refers to Ahead-of-Time compilation, not the new ART ;)

        • Andrew Grush

          Correct, Javier — I’m refering to Ahead-of-Time compilation. Though to be fair to Dan, I still made a typo. It should be AOT not AHT… fixing now. :)

          • Javier Rapoport

            Right, JIT vs AOT :)

            I noticed WhatsApp decided to crash and won’t even install… I think we can blame ART for that…? Anyone seeing the same?

            • Sergio Josemar Pavez Vera

              yep me too, I’m on Nexus 4, android 4.4 with ART on, whatsapp issue on it.

    • Shark Bait

      Sounds like some solid work Google! Once again it proves that KitKat isn’t the minor upgrade people talk about

    • MSmith79

      That’s awesome! Can’t wait. Although I’ve never experienced the “so-called app/UI lag” on any high-end smart phone.

      • Zacisblack

        Download Facebook->Open Facebook->Scroll->LAG regardless of how powerful of a smartphone you have.

        • digital4trees

          Agreed. Although Google “fasterbook” for examples of how fb is dragging its feet with lag.

    • Javier Rapoport

      First casualty I found is WhatsApp… Can anyone else confirm that it’s effectively not working when switching to ART?

      • digital4trees

        Yup. Same here. Instantly crashed in the background and wouldn’t restart. Shame really as that’s a showstopper for me.

        • FZ

          Did you try to uninstall and re-install it? As I understood, the AOT compilation happens during installation so figured it’s worth the try.

          • digital4trees

            Not yet. Enabling AOT forced the phone to optimise all apps anyway so I’m guessing it wouldn’t help

            • FZ

              You’re probably right then

            • digital4trees

              Update: Turned the new runtime back on, all apps updated. Uninstalled WhatsApp. Re-downloaded WhatApp – the install of which seemed to take a LOT longer than usual and then it crapped out with a package error. So WhatsApp not only won’t run, it straight up won’t install on the new runtime. Back to Dalvik we go….for now :)

            • digital4trees


              I now cannot reinstall the app at all, even after several reboots and installation attempts. I’ve even tried downloading the apk directly from the developer.

              It would seem that enabling this runtime makes some permanent updates to your phone that could harm installation of apps, even if you switch back to the old runtime.

            • http://blog.tonysarju.com/ Tony Sarju

              Are you getting Error 24 when trying to reinstall from Google Play? Try this fix in either case: http://forum.xda-developers.com/showthread.php?t=2027663

            • digital4trees

              Yup. Actually error -24 :D Slight problem with the instructions on your link:
              1. I’m not rooted.
              2. There’s nothing in /data let alone another folder called data


            • http://blog.tonysarju.com/ Tony Sarju

              Unfortunately you need to be rooted to see the contents of that folder under /. You’re going to have to factory reset I suppose.

            • digital4trees

              Gnnnnnnnnn. That’s really annoying! :D I’ve had this phone 2 days and I’m already having to reset everything?! ffs.

            • CyberAngel

              When KitKat comes to S4A I’m going to stay ART
              I’ll use those apps that are ART compatible.
              It sounds like the performance will be marvellous
              I hope my battery life doubles…

            • david

              I had the same problem, but i can install whatsup in dalvik from Google Play Web

            • Kelly Caffrey

              Well this is scary, I use whatsapp big time and currently my phone is updating to the new runtime
              I should’ve read the comments first :o.

            • CyberAngel

              Factory Reset

            • Mikel Pr

              nope it’s probably some odex or other app files that were left over that aren’t letting the package manager install it
              try to install via adb and look up the error code given

            • Seth Forbus

              Yes because a master reset is soooo hard to do.

            • digital4trees

              Didn’t say it was hard but its undeniably time consuming and frustrating. Plus, you’re guaranteed to lose a few things in the process: game progress and the like.

            • KramitDfrog

              That’s funny – just switched over to ART, confirmed the issue with whatsapp, went back to dalvik and I have no issues with whatsapp. Started as normal.

        • Jayfeather787


    • Clarence Alvarado

      “the end result is that apps will launcher quicker…” It should be launch

      • MasterMuffin

        Also “On the downside, the AOT method ” should be ART :)

        • Mirzet Kadic

          No, AOT= Ahead of Time comilation

          • MasterMuffin

            Oops I didn’t even read that part, I just saw AOT when everywhere else there’s ART :)

            Oh and *compilation >:D

    • Tiago Alves

      I think a question most of us have is: how stable is it? Is it stable enough to use in a daily basis?
      Can someone that has been using ART share the experience?

      • Jayfeather787

        It’s not super stable, but stable enough. One app crashed. (Whatsapp)

    • Jayfeather787

      I tried ART and the phone was definetly a lot smoother, but some apps kept crashing.

    • martin carlosena

      This is some exciting stuff. I’m really looking forward to this. Hopefully the android team can have this ready for the next major OS release. o/

    • fgrhuhrg

      Can’t find this option in my developer options. Using a 2012 nexus 7 WiFi only