Main Memory: The Workhorse
Main memoryโyour RAMโis like the busy backstage where actors wait for their cue. It holds everything the CPU needs right now.
DRAM
Dense but slightly forgetful worker that needs constant refreshing
SRAM
Quicker and more reliable but pricey, usually lives in cache
ROM
Permanent instructions like the BIOS that boots your computer
๐DRAM vs SRAM
DRAM (Dynamic RAM) stores each bit in a separate capacitor that must be periodically refreshed. It's cheaper and denser, making it ideal for main memory.
SRAM (Static RAM) uses flip-flops to store bits, so it doesn't need refreshing. It's faster but more expensive, making it perfect for cache memory.
๐งROM Variants
ROM (Read-Only Memory) comes in several flavors:
PROM
Programmable once
EPROM
Erasable with UV light
EEPROM
Electrically erasable
Flash Memory
Modern rewritable non-volatile memory