~2ns access time. Super fast. The decoders are big and the array is big.
Really damn expensive, and with a high area requirement. Volatile: requires constant power, or resets memory.
Slower: ~60ns access time. Hurry up and wait design philosophy doesn't work here.
Costs 0.2% as much as SRAM per megabyte. Still really expensive. Volatile: requires constant power, or resets memory.
Slower still: ~250ns access time.
Costs 10% of DRAM per megabyte. Non-volatile: Does not get reset with computer reset.
These are obnoxiously slow, because they are waiting for a physical device which is spinning so you can read the actual bits you want.
Gives access times that are in 300Hz range. Maybe 300-400 times a second.
However, this is super super cheap, and non-volatile.
Sounds crazy and ridiculous, but people really do this. Facebook has a system called "Cold Storage", where they burn your super old photos.
Choose one.
Can we combine multiple memory technologies?
You can build multiple levels of SRAM caches, then you can switch to DRAM, and finally go down to flash or disk.
Don't try to buy \(2^{64}\) bytes of anything. Virtual memory makes it look like the entire address range is available. A few TB is enough for most machines today.
The architectural view of memory is
Don't tell programmer about this!
Breaking up the memory system into different pieces – cache, main memory and disk – is not architectural. Part of the microarchitecture
The cache will hold data that we think is most likely to be referenced.
Cache memory can copy data from part of any part of main memory
Instead of thinking of memory as an array of data indexed by a memory address, think of memory as a det of data matching a query
Operations:
You want to kick out the one that results in the fewest total misses in the program execution. A guy named Belady made an algorithm (Belady's Algorithm) that goes to an oracle and tells you the line that is accessed the furthest into the future.
If programs were random, any address is just as likely to be reused as any other address. HOWEVER, programs are not random. They tend to use the same memory locations over and over. We can use this to pick the most referenced locations to put into the cache.