How does expandable RAM works in phones

One of the many new terms that appear in smartphone data sheets is virtual RAM. The feature, which was originally found on some mid-range phones, is now making its way into budget phones like the Redmi 10 Prime and even premium phones like the vivo X60 series.
While the extra RAM sounds pretty good when needed, how exactly does it work? We have taken a close look at all the pros and cons. How does expandable virtual RAM work? Expandable Virtual RAM (Random Access Memory) reserves a predetermined portion of your phone’s internal memory to store temporary files or RAM tasks when more RAM is needed. RAM is important in most computing devices as it determines how fast or slow your phone or even your PC will perform.
The lower the RAM, the slower the device will run. If you use a large part of your RAM on a smartphone, the expandable virtual RAM feature sends temporary files to this reserved internal storage space. This will free up more space in your actual physical RAM to load more applications. When you want to go back to older applications, the phone will bring these temporary files from its internal storage to RAM so that you can use those applications again. The RAM shortage has never stopped us from opening newer apps on phones that don’t have expandable virtual RAM.
So what is really changing? The answer is simple: On phones without this feature, as you open more applications and use your available RAM, Android Optimization begins to remove temporary application files in the background, in a process we call RAM Optimization. This allows you to use newer applications, but when you return to the previous application (which is still on your recent applications screen) you will find that the application will restart instead of continuing from the screen that was left.
Take the same phone with the same amount of RAM, say 6GB, except this time you are using a phone with expandable virtual RAM. If you have enough applications open, those 6GB of RAM are almost full. The virtual RAM feature will now be enabled and will use the extra 2GB allotted space to process background apps. The phone intelligently handles the extra data load into RAM rather than forcing older apps to close.
Thus, the feature allows you to open more applications on a phone without closing older applications in the background. In terms of performance, the actual physical RAM will always be faster and more reliable. This is because RAM speeds are much faster than internal storage speeds and even exceed the speeds of UFS 3.1, one of the fastest internal storage options we can get in phones today. When we use expandable virtual RAM, a lot of data is transferred from RAM to internal storage and vice versa. This process is also carried out more slowly than with transfers that take place entirely within the RAM module, since the comparatively slower internal memory is involved. So the feature is more of a backup of RAM when you need it, rather than a replacement for more RAM.