Technology and Operating Systems

Lecture Notes for CS 140
Winter 2012
John Ousterhout

  • Many of the basic ideas in operating systems were developed 30-40 years ago, when technology was very different. Are these ideas still relevant today and in the future?
  • Technology changes over the last 25 years:
    • CPU speeds: 15 MHz -> 2.5 GHz (167x)
    • Memory size: 8 MBytes -> 4 GBytes (500x)
    • Disk capacity: 30 MBytes -> 500 GBytes (16667x)
    • Disk transfer rate: 2 MBytes/sec -> 100 MBytes/sec (50x)
    • Network speed: 10 Mbits/sec -> 1 Gbit/sec (100x)
  • The role of paging:
    • When originally proposed (1960's):
      • Disk speed: 80ms latency, 250 KBytes/sec transfer
      • Memory size: 256 KBytes (64 pages)
      • Time to replace all of memory:
        • 6.4 sec (random access)
        • 1 sec (sequential)
    • Today:
      • Disk speed: 10ms latency, 100 MBytes/sec transfer
      • Memory size: 4 GB (1,000,000 pages)
      • Time to replace all of memory:
        • 10,000 sec (3 hours) (random access)
        • 40 sec (sequential)
    • Can't afford to page something out unless it's going to be idle for a long time.
    • Does paging make sense anymore?
      • Mechanism for incremental loading of processes?
        • Why not just read the entire binary at once?
        • 10 MB of binary takes .1 sec.
      • Safety valve for temporary emergencies?
        • Perhaps, but not much space between "system not paging at all" and "system totally unusable".
      • Convenient for managing physical memory.
    • Page size is too small:
      • Random accesses for replacement too expensive.
      • Not enough TLB coverage.
  • TLBs:
    • Haven't kept up with memory sizes
    • 64 entries -> 256 KBytes coverage
    • In mid-80's this was a substantial fraction of memory (8 Mbytes).
    • Today TLBs can only cover a tiny fraction of memory
    • Some TLBs support larger page sizes:
      • 1 MByte
      • 1 GByte
      • But, this complicates kernel memory management.
  • Multi-cores
    • For many years, chip technology improvements allowed processor clock rates to improve rapidly.
    • Unfortunately, faster clock rates mean more power dissipation; power limitations now limit improvements in clock rate.
    • Chip designers are now using technology to put more processors (cores) on a chip.
    • Consequences:
      • All OSes must now be multiprocessor OSes
      • Not clear how to utilize all of these cores: app developers must now write parallel programs?
      • Writing parallel programs is very hard
  • Current hot areas for OS development:
    • Very small (devices)
      • Android, iPhone, etc.
    • Very large (datacenters)
      • Coordinating thousands of machines working together
  • RAMCloud project: see slides