Technical Differences Between Google's Gingerbread and Ice Cream Sandwich
Ever thought about how Gingerbread (GB) and Ice Cream Sandwich (ICS) platforms differ on a technical level. Will you go for the new features on ICS or will you prioritise stability and stay on Gingerbread?
It is well-known that Ice Cream Sandwich is more intensive in terms of memory usage. As smartphones become more capable, applications are becoming more advanced, which means that they require more CPU power, run more network activities and use more RAM. On the other hand, ICS brings a refined UI and some nice new features.
From a UI perspective, ICS is based on a new look and feel, the Holo theme. The graphical assets of the Holo theme cannot be changed in any way as stated in the Android Compatibility Definition Document (CDD).
In ICS, the activity manager has a completely new UI, where all running apps are shown as thumbnails in a list. To close an activity, you can it out of the list. ICS also introduces a face recognition app as a way to unlock the phone, called Face Unlock. Face Unlock uses the front-facing camera and advanced object recognition algorithms.
The contact list will show more information about the contacts, including updates from social networks. In the calendar, colour coding has been added and it is now possible to zoom. There is also support for a new type of voicemail that is more visual, offering transcriptions of voice messages.
When it comes to ICS, it's a major upgrade of Android, and there are a lot of things that have changed compared to the Gingerbread release. Some of these changes affect the performance and stability of the system, for example by using more CPU power and RAM. ICS was developed with Galaxy Nexus in mind, which is based on a TI platform with dual-core processor and 1GB RAM. Mobile makers have to adapt ICS to run on their smartphones built on other single-core platforms and 512 MB RAM. This means that in some cases, the resource usage in ICS impacts the performance of the system and the user experience might not be as good as when running on Gingerbread.
In general, it can be said that the RAM is the working memory in the phone, used by running processes in contrast to the flash memory, which is mainly used to store things.
In a 512MB RAM smartphone, about a third is used for functions that require a dedicated memory slot to operate fast enough. The remaining space, which is at least 340MB, is reserved for the Linux user space, as required in the Android Compatibility Definition Document (CDD). Within the Linux user space, functions like the activity manager and Home screen app are running.
Another interesting thing is that many apps use slightly more RAM in ICS. For example, the web browser is quite intensive, and generally uses 20-30MB more in ICS compared to Gingerbread. All in all, there are a lot of changes that together result in greater RAM requirement.
When running low on RAM, typically with less than approximately 40MB left, the activity manager will start to close processes according to priority. At first, idle background activities are killed. The last thing to be closed down is the foreground activity.
Processes that are closed will obviously have to be restarted when the user enters the app again, which takes time and slows the system down.
Another change in ICS compared to Gingerbread is that Google has moved a lot of the SQL handling from the native to the Java layer. Studies conducted by Sony Mobile's engineers showed that that read and write operations to the SQL database takes longer time, which slows down the apps. Many applications perform a lot of SQL operations when started, which greatly impacts the start-up time.
According to good practice, database operations or http requests should not be performed in the main thread. However, there are quite a few applications that perform these kinds of operations directly in the main thread, which might cause them to hold up other operations. Also, comments online indicate that people having problems with some applications and games.
If an operation takes too long, there is a risk of getting an Application Not Responding (ANR) as a result. An ANR occurs when an application doesn?t answer an intent, or responds to an input event, within a certain time limit. In case of intent, the time out is set to five seconds. For the input event, such as screen touch or button click, it's ten seconds. This can result in a user experience that is perceived as slower and less stable, due to longer response times and increased ANRs.
Yet another change in ICS, is that the graphics hardware acceleration is on by default for all apps from API level 14. For apps at lower API levels, it can be turned on in the manifest with the attribute Android:hardwareAccelerated="true". Hardware acceleration means that the GPU is used to render graphics, which enables a smooth user interface. However, it also results in at need to load additional graphic libraries for certain apps, which makes them use even more RAM.
Sony Mobile's internal tests on its applications showed that the Settings app consumed 1-2MB more RAM, and actually took longer time to start with HW acceleration, compared to without. Once the app is running, the UI is HW accelerated, but unless the app performs advanced graphics, the user will not see the difference.
Another effect of the hardware acceleration is that it can make the battery drain faster in some cases. An example of this is video playback, where the hardware acceleration requires every video frame to be run through the GPU, thus making the system use more power than it would have without HW acceleration.
From a UI perspective, ICS is based on a new look and feel, the Holo theme. The graphical assets of the Holo theme cannot be changed in any way as stated in the Android Compatibility Definition Document (CDD).
In ICS, the activity manager has a completely new UI, where all running apps are shown as thumbnails in a list. To close an activity, you can it out of the list. ICS also introduces a face recognition app as a way to unlock the phone, called Face Unlock. Face Unlock uses the front-facing camera and advanced object recognition algorithms.
The contact list will show more information about the contacts, including updates from social networks. In the calendar, colour coding has been added and it is now possible to zoom. There is also support for a new type of voicemail that is more visual, offering transcriptions of voice messages.
When it comes to ICS, it's a major upgrade of Android, and there are a lot of things that have changed compared to the Gingerbread release. Some of these changes affect the performance and stability of the system, for example by using more CPU power and RAM. ICS was developed with Galaxy Nexus in mind, which is based on a TI platform with dual-core processor and 1GB RAM. Mobile makers have to adapt ICS to run on their smartphones built on other single-core platforms and 512 MB RAM. This means that in some cases, the resource usage in ICS impacts the performance of the system and the user experience might not be as good as when running on Gingerbread.
In general, it can be said that the RAM is the working memory in the phone, used by running processes in contrast to the flash memory, which is mainly used to store things.
In a 512MB RAM smartphone, about a third is used for functions that require a dedicated memory slot to operate fast enough. The remaining space, which is at least 340MB, is reserved for the Linux user space, as required in the Android Compatibility Definition Document (CDD). Within the Linux user space, functions like the activity manager and Home screen app are running.
Another interesting thing is that many apps use slightly more RAM in ICS. For example, the web browser is quite intensive, and generally uses 20-30MB more in ICS compared to Gingerbread. All in all, there are a lot of changes that together result in greater RAM requirement.
When running low on RAM, typically with less than approximately 40MB left, the activity manager will start to close processes according to priority. At first, idle background activities are killed. The last thing to be closed down is the foreground activity.
Processes that are closed will obviously have to be restarted when the user enters the app again, which takes time and slows the system down.
Another change in ICS compared to Gingerbread is that Google has moved a lot of the SQL handling from the native to the Java layer. Studies conducted by Sony Mobile's engineers showed that that read and write operations to the SQL database takes longer time, which slows down the apps. Many applications perform a lot of SQL operations when started, which greatly impacts the start-up time.
According to good practice, database operations or http requests should not be performed in the main thread. However, there are quite a few applications that perform these kinds of operations directly in the main thread, which might cause them to hold up other operations. Also, comments online indicate that people having problems with some applications and games.
If an operation takes too long, there is a risk of getting an Application Not Responding (ANR) as a result. An ANR occurs when an application doesn?t answer an intent, or responds to an input event, within a certain time limit. In case of intent, the time out is set to five seconds. For the input event, such as screen touch or button click, it's ten seconds. This can result in a user experience that is perceived as slower and less stable, due to longer response times and increased ANRs.
Yet another change in ICS, is that the graphics hardware acceleration is on by default for all apps from API level 14. For apps at lower API levels, it can be turned on in the manifest with the attribute Android:hardwareAccelerated="true". Hardware acceleration means that the GPU is used to render graphics, which enables a smooth user interface. However, it also results in at need to load additional graphic libraries for certain apps, which makes them use even more RAM.
Sony Mobile's internal tests on its applications showed that the Settings app consumed 1-2MB more RAM, and actually took longer time to start with HW acceleration, compared to without. Once the app is running, the UI is HW accelerated, but unless the app performs advanced graphics, the user will not see the difference.
Another effect of the hardware acceleration is that it can make the battery drain faster in some cases. An example of this is video playback, where the hardware acceleration requires every video frame to be run through the GPU, thus making the system use more power than it would have without HW acceleration.