Ram is high speed, volatile memory:
RAM (Radom Access Memory) is used as the main memory in a computer. It can be read or written to. RAM is volatile.
- Volatile memory is temporary memory. It requires power to retain its data.
- Non-volatile memory is permanent memory – It keeps its contents even when it has no power.
The main memory is where all data, files and programs are stored while they’re being used.
When a computer boots up, the operating system is copied from the secondary storage to RAM.
Virtual Memory is Secondary Storage used as extra RAM:
When software applications, documents, and files are opened. They are copied from the secondary storage to RAM . They stay in RAM until the files or applications are closed.
Ram is slower than the CPU cache, but faster than secondary storage.
- Computers have a limited amount of RAM. As applications are opened, RAM fills with data.
- When RAM is full, the computer needs somewhere else to store the data. It moves data that hasn’t been used recently to a location on the secondary storage known as virtual memory.
- Virtual memory may be needed if there are too many applications opened at once, or if a particularly memory-intensive application (due to data constantly moving between virtual memory and RAM just to keep the program running.
- If the CPU needs to read data stored in virtual memory, it must move it back to the RAM. This is slow as data transfer rates are much slower on secondary storage than RAM.
- Using virtual memory a lot can slow down your computer as it is continuously getting swapped between the virtual memory and RAM; or when using a memory-intensive application.
By Anshjeet Singh
Subscribe to My Newsletter for weekly articles all for FREE!
No responses yet