Primary Storage

ROM

ROM, an acronym of Read Only Memory, shockingly enough can only be read from, not written to. It’s also non-volatile, which means its data doesn’t disappear when the power is turned off. This is useful, because it stores something called the BIOS- instructions for a computer to boot up and load the operating system.

RAM

RAM is an acronym of Random Access Memory- not to be confused with Daft Punk’s Random Access Memories. This is where all data, files and programs are stored whilst they’re being used. This includes anything from the software applications, documents and even the operating system. When they are opened, they are copied from secondary storage, like a hard drive or flash drive, into the RAM, and stay in the RAM until they’re closed. RAM is a type of read-write and volatile memory, which means the data is only retained whilst it has power. This is why your operating system and running programs all restart when you restart your computer.

Virtual Memory

Now, although I said there are 2 main types of primary storage, there is also a concept known as Virtual Memory. Since RAM is finite, a computer needs somewhere else to put application data when the RAM is full, which can happen if there are too many applications open at once, or a memory-intensive app is being used (or both). When this happens, the computer will move data that hasn’t been used recently, to a location on secondary storage, such as the hard drive, and this is known as virtual memory. It’s like a big shelf where your computer stores things that it doesn't need right away.

It’s not a completely perfect solution though, as this affects performance due to the delay when transferring data from secondary storage back into RAM. This means that more RAM means virtual memory is less likely to be needed, which generally means better performance.

Summary

The 3 key differences between ROM and RAM are concerned with volatility, write access and what they store:

Virtual Memory is a concept used when RAM is full, allowing a computer to move data that hasn't been used recently to secondary storage, such as the hard drive, to free up RAM for more intensive applications.


Next
Next

Embedded Systems