X

Android 4.4 KitKat's New Memory Management Brings Significant Optimization

Featured image for Android 4.4 KitKat's New Memory Management Brings Significant Optimization

With each iteration and update, Android has grown more hungry as the list of features grows.  This can be seen in particular on Samsung’s devices, where Samsung packs a ton of features into the OS, and as such nearly always has the recognition of shipping phones with more RAM than anyone else.  The Galaxy Note 3 is the first phone to ship with 3GB RAM on board, and for good reason.  Seeing this trend get crazy out of hand, Google has decided to do something about it in it’s latest version of Android, Android 4.4 KitKat.  KitKat brings the memory requirements down to just 512MB of RAM, which is half that of the last few versions of Android.  While it seems like a nice gesture and may sound fairly simple to do, this sort of feat is not one easily achieved on a platform as large and diverse as Android, which spans across tens of thousands of different types of hardware.  This meant that Google had to change how Android works under the hood, and had to intelligently redesign the way Android launches apps and keeps them in memory, and how it handles switching back and forth between tasks.

On its own Android Developers Blog, Google explains exactly how they did what they did to achieve this end result.  Google has built-in a brand new set of low-level controls that let manufacturers of entry-level devices, which usually ship with only 512MB of RAM, tune these devices to optimal levels.  They can now control things like graphic cache sizes, tune out-of-memory levels for processes, swap to zRAM and many more optimizations.  Google has also added in a new aggressive memory protection algorithm that will keep apps from using too much RAM, especially for these entry-level devices.

samsungdram

There’s now a new tag in the development language that allows developers to modify the app based on whether the phone is a “LowRamDevice” as the code puts it, and allows the app to have a modified behavior from a phone with plenty of RAM to spare.  Users of all Android phones will also be pleased to hear that apps are only allowed to start serially instead of parallelly, which means that apps must start one at a time rather than all at once.  Those who have had their phone completely lock up for a few seconds or more because too much stuff was going on at once will know exactly what I’m talking about.  There’s also new developer tools that let developers test phone RAM usage and lets them optimize their apps for lower specced phones.  Getting those budget phones up to the latest version of a cutting edge operating system is no small task, but the steps they’ve taken seem like they will bring Android to a whole new level of fluidity and efficiency, even for higher end phones that tend to be able to brute force their way to the task at hand.

  翻译: