Thursday, 15 November 2007

Flash RAM instead of harddisks

Flash drives have become larger and less expensive, and it doesn't take a lot of experimenting to find out, that a laptop can become faster, quieter, more robust and have a longer battery life, if you replace your harddisk with flash RAM. And then there's the fact, that good quality flash RAM systems outlive even very expensive harddisks easily.

What do flash drives mean for software developers? Here are a couple of consequences:
  • When multiple threads compete for disk access, responsiveness will benefit greatly. This means that background threads that access disks will be more likely.
  • Disk space becomes more expensive for a while, favoring apps that don't waste space too much.
  • It becomes less necessary to prefetch small amounts of data from the local disk. For some applications, this can reduce RAM usage.
  • Reduced seek time means that different file formats may become optimal. This includes different ways of indexing, but it may also mean less redundancy in file formats.
Because of the huge benefits of flash RAM, less disk space will be considered acceptable, and often, this makes it realistic to have more RAM in the PC, than there is flash RAM. This makes it obvious to cache everything on the flash - and it can be cached by the OS file system or by the application.


gabr said...

That's all good and well, but how much does, say, 60 GB flash drive cost?

Lars D said...

Why spend $10,000 on programmers trying to improve performance 20%, if you can more than double the performance for $800?

Anyway, a $20 1GByte flash drive makes my laptop run Ubuntu Linux faster, than if I would run it from the harddisk.

A Firebird database server with a 1GByte database can be done easily on a $40 4GB flash drive with good performance. If you want extreme performance, a 32GB flash drive can be bought at $800.

Lars D said...

I just stumbled on this link, which shows some statistics and trends of flash memory. It shows how flash is actually cheaper per I/O for read/only purposes than a harddisk.

In other words, if you need something that can deliver a lot of data, flash is the cheapest choice.