All the necessary hardware is there like CPU, RAM, GPU, Modem, Signal Processor, etc. The CPU processes the application threads and the data being used by it is stored on the RAM.
I want to keep it simple for everybody to understand.
In layman terms, a phone lags when it is put to a task it can not handle.There are multiple threads being processed by a smartphone even when it is not being used by you and lying idle.
---
# If the CPU has to process multiple long threads, it lags as soon as things get beyond its processing capability. As and when it happens the SoC heats up and that further promotes lag and stutter because an overheated CPU is like an exhausted horse.
Not to forget, there is a GPU as well which is a processor which only deals with graphics and visuals which you see on the display, and the same principle applies to it as well but only in context of graphic processing.
And even if the CPU and GPU are good at computing everything which you throw at them, you need to have enough memory i.e. RAM to keep all those threads running.
-
MORAL - Your smartphone should be equipped well with good quality hardware to handle all tasks which you require to perform on it.
SoCs with smaller thermal footprint are more efficient. That is why newer SoCs are made using smaller nano-architecture because it helps in keeping the SoC from overheating while performing great on heavy gaming. For example- Snapdragon 805 is built using 28nm architecture whereas the upcoming 808 and 810 use 20nm technology to reduce thermal footprint and enhance efficiency.
---
# Many applications especially on Android OS keep running in the background and you can't kill them if you don't feel like using them at that moment. These include all the utility apps, Facebook, Maps, Youtube, Mail, Google+ and many other third-party apps as well.
The moment you kill them with a task killer, they re-appear. Killing such an application never helps, it only makes harder for the CPU as it has to re-work the thread.
-
MORAL - Don't use a task killer for all-time running apps. Never use the auto-kill feature on a task killer. The CPU is programmed well to manage multiple apps.
---
# Now the question arises that why do smartphones start to lag as time passes. Its simple. As we are progressing in the Android ecosystem, the apps are getting heavier, more data-intensive, graphic-intensive with every update which requires more memory and processing power. As a result, the amount of free-RAM for a new heavy thread to be processed (like when you start a 3D game) keeps diminishing with time and keeping the same old CPU for heavier new apps shouldn't help.
-
MORAL - Only load your phone with apps which are essential to you if you are low on hardware terms. As we go ahead in time our smartphones go obsolete due to advancement in application softwares. Although some major enhancements in system softwares like Project Butter and replacing Dalvik Runtime with ART on Android helps a lot in achieving a lag-free experience.
---
SUMMING IT UP...
Both hardware and software advancements go hand in hand. Hardware has to be enhanced to cater to the needs of heavier and more-feature rich OS and apps. As far as the current scenario looks, the hardware seems to take the lead because its getting both cheaper and more advanced with time.
Three years ago, when I bought my first smartphone with a single-core processor and 512MB RAM for INR 16.7K, any other cheaper phone couldn't offer a lag-free experience due to one or other reason. And even my phone started lagging after a year even with essential pre-loaded apps.
But today, you get a phone for INR 6K which offers good lag-free performance on essential apps with a far more efficient Quad-core CPU, 1GB RAM, Stock Android with 60fps transitions, no bloatware and prompt firmware updates.
And by this I don't mean to say that the new cheaper phone with better hardware will never lag or stutter but it will definitely take more time for it to be rendered as a brick.
With the coming of technologies like ARMv8 instruction set, tinier nano-architecture on chips, 64-bit SoCs and OS, ART, etc. the future seems bright and lag-free.