Chapter Goals

73
1 Systems Architecture, Fifth Edition Chapter Goals Describe the distinguishing characteristics of primary and secondary storage Describe the devices used to implement primary storage Describe memory allocation schemes Compare and contrast secondary storage technology alternatives

description

Chapter Goals. Describe the distinguishing characteristics of primary and secondary storage Describe the devices used to implement primary storage Describe memory allocation schemes Compare and contrast secondary storage technology alternatives. Chapter Goals (continued). - PowerPoint PPT Presentation

Transcript of Chapter Goals

Page 1: Chapter Goals

1Systems Architecture, Fifth Edition

Chapter Goals

• Describe the distinguishing characteristics of primary and secondary storage

• Describe the devices used to implement primary storage

• Describe memory allocation schemes• Compare and contrast secondary storage

technology alternatives

Page 2: Chapter Goals

2Systems Architecture, Fifth Edition

Chapter Goals (continued)

• Describe factors that determine storage device performance

• Choose appropriate secondary storage technologies and devices

Page 3: Chapter Goals

3Systems Architecture, Fifth Edition

Page 4: Chapter Goals

4Systems Architecture, Fifth Edition

Page 5: Chapter Goals

5Systems Architecture, Fifth Edition

Characteristics of Storage Devices

• Speed• Volatility• Access method• Portability• Cost and capacity• Let’s examine each of these...

Page 6: Chapter Goals

6Systems Architecture, Fifth Edition

Speed

• Primary storage speed– Typically faster than secondary storage speed by a

factor of 105 or more

– Expressed in nanoseconds (billionths of a second)

• Secondary storage speed– Expressed in milliseconds (thousandths of a second)

• Data transfer rate = 1 second/access time (in seconds) x unit of data transfer (in bytes) (simplified)

Page 7: Chapter Goals

7Systems Architecture, Fifth Edition

Volatility

• Primary storage devices are generally volatile– Cannot reliably hold data for long periods

• Secondary storage devices are generally nonvolatile– Hold data without loss over long periods of time

Page 8: Chapter Goals

8Systems Architecture, Fifth Edition

Access Method

• Serial access (linear, such as a tape)• Random access (direct access, such as RAM)• Parallel access (simultaneous access, such as

RAID)

Page 9: Chapter Goals

9Systems Architecture, Fifth Edition

Portability

• Removable storage media with standardized formats (e.g., compact disc and tape storage)

• Typically results in slower access speeds

Page 10: Chapter Goals

10Systems Architecture, Fifth Edition

Cost and Capacity

• Cost increases:– With improved speed, volatility, or portability

– As access method moves from serial to random to parallel access method

• Primary storage - expensive (high speed and combination of parallel/random access methods)

• Capacity of secondary storage devices is greater than primary storage devices

Page 11: Chapter Goals

11Systems Architecture, Fifth Edition

Page 12: Chapter Goals

12Systems Architecture, Fifth Edition

Memory-Storage Hierarchy

Page 13: Chapter Goals

13Systems Architecture, Fifth Edition

Primary Storage Devices

• Critical performance characteristics– Access speed

– Data transfer unit size

• Must closely match CPU speed and word size to avoid wait states

Page 14: Chapter Goals

14Systems Architecture, Fifth Edition

Storing Electrical Signals

• Directly– By devices such as batteries and capacitors

– Trade off between access speed and volatility

• Indirectly– Uses energy to alter the state of a device; inverse

process regenerates equivalent electrical signal

• Modern computers use memory implemented with semiconductors (RAM and NVM)

nonvolatile memory

Page 15: Chapter Goals

15Systems Architecture, Fifth Edition

Random Access Memory• Characteristics

– Microchip implementation using semiconductors

– Ability to read and write with equal speed

– Random access to stored bytes, words, or larger data units

• Basic types– Static RAM (SRAM) – faster than DRAM; uses 6

transistors/bit; does not need refreshing; faster than DRAM

– Dynamic RAM (DRAM) – uses 1 transistor and 1 capacitor / bit; cheaper than SRAM; needs refreshing; higher density; needs more power requirements

Page 16: Chapter Goals

16Systems Architecture, Fifth Edition

Random Access Memory

• To bridge performance gap between memory and microprocessors– Read-ahead memory access

– Synchronous read operations

– On-chip memory caches

Page 17: Chapter Goals

17Systems Architecture, Fifth Edition

Nonvolatile Memory

• Random access memory with long-term or permanent data retention

• Usually relegated to specialized roles and secondary storage; slower write speeds and limited number of rewrites

• Generations of devices (ROM, EPROM, and EEPROM)

Page 18: Chapter Goals

18Systems Architecture, Fifth Edition

Nonvolatile Memory

• Flash RAM (most common NVM)– Competitive with DRAM in capacity and read

performance

– Relatively slow write speed

– Limited number of write cycles (more on this later)

• NVM technologies under development– Ferroelectric RAM

– Polymer memory

Page 19: Chapter Goals

19Systems Architecture, Fifth Edition

Memory Packaging

• Dual in-line packages (DIPs)– Early RAM and ROM circuits

• Single in-line memory module (SIMM)– Standard RAM package in late 1980s

• Double in-line memory module (DIMM)– Newer packaging standard

– A SIMM with independent electrical contacts on both sides of the module

Page 20: Chapter Goals

20Systems Architecture, Fifth Edition

Page 21: Chapter Goals

21Systems Architecture, Fifth Edition

CPU Memory Access

• Critical design issues for primary storage devices and processors– Physical organization of memory

– Organization of programs and data within memory

– Method(s) of referencing specific memory locations

Page 22: Chapter Goals

22Systems Architecture, Fifth Edition

Physical Memory Organization

• Physical memory– Actual number of memory bytes that physically are

installed in the machine

• Most and least significant bytes• Big endian (stores most significant byte/bit at

lowest memory address) and little endian• Addressable memory

– Highest numbered storage byte that can be represented

Page 23: Chapter Goals

23Systems Architecture, Fifth Edition

Page 24: Chapter Goals

24Systems Architecture, Fifth Edition

Page 25: Chapter Goals

25Systems Architecture, Fifth Edition

Memory Access Time

• Memory rated at PCxxxx delivers peak bandwidth of xxxxMB/sec.

• For example, PC3200 memory delivers 3.2GB/sec peak bandwidth.

• Typically, there is a significant delay before you can get back the first byte (say 6 cycles)

• Random accesses would deliver around 500KB/sec.

Page 26: Chapter Goals

26Systems Architecture, Fifth Edition

Memory compared to CPU

• How much data can a CPU pump around?• 2GHz = 2,000,000 cycles per second• Each cycle, the CPU can move around a word

(4 bytes on a 32-bit machine)• so 8GB/sec

Page 27: Chapter Goals

27Systems Architecture, Fifth Edition

Magnetic Storage

• Exploits duality of magnetism and electricity– Converts electrical signals into magnetic charges

– Captures magnetic charge on a storage medium

– Later regenerates electrical current from stored magnetic charge

• Polarity of magnetic charge represents bit values zero and one

Page 28: Chapter Goals

28Systems Architecture, Fifth Edition

Page 29: Chapter Goals

29Systems Architecture, Fifth Edition

Page 30: Chapter Goals

30Systems Architecture, Fifth Edition

Page 31: Chapter Goals

31Systems Architecture, Fifth Edition

Magnetic Tape

• Ribbon of plastic with a coercible (usually metallic oxide) surface coating

• Mounts in a tape drive for reading and writing• Relatively slow serial access• Compounds magnetic leakage; wraps upon itself• Susceptible to stretching, friction, temperature

variations

Page 32: Chapter Goals

32Systems Architecture, Fifth Edition

Page 33: Chapter Goals

33Systems Architecture, Fifth Edition

Magnetic Tape

• Two approaches to recording data– Linear recording

– Helical scanning

• Several formats and standards (e.g., DDS [DAT], AIT, Mammoth, DLT (digital linear tape), LTO (linear tape-open))

• Highest capacity tapes hold about 1 TB (same as largest disk drives)

• But much cheaper per byte

Page 34: Chapter Goals

34Systems Architecture, Fifth Edition

Page 35: Chapter Goals

Modern Tape Formats and Capacities (uncompressed)

• DDS (DAT), from Sony and HP: 2-36 GB• AIT, from Sony: 35-400 GB• Mammoth, from Exabyte: 20-80 GB• DLT, from Quantum: 20-600 GB• LTO, from HP, IBM, Seagate: 100-800 GB

35Systems Architecture, Fifth Edition

Page 36: Chapter Goals

36Systems Architecture, Fifth Edition

Magnetic Disk

• Flat, circular platter with metallic coating that is rotated beneath read/write heads

• Random access device; read/write head can be moved to any location on the platter

• Hard disks and floppy disks• Cost performance leader for general-purpose

on-line secondary storage

Page 37: Chapter Goals

37Systems Architecture, Fifth Edition

Page 38: Chapter Goals

38Systems Architecture, Fifth Edition

Page 39: Chapter Goals

39Systems Architecture, Fifth Edition

Magnetic Disk Access Time

• Head-to-head switching time• Track-to-track seek time• Rotational delay• Most important performance numbers

– Average access time

– Sequential access time

– Sustained data transfer rate

Page 40: Chapter Goals

40Systems Architecture, Fifth Edition

Average Access Time

• Head switching time (negligible)• Plus head seek time (given in ms)• Plus rotational delay (on average, ½ a turn)

If disk spins at 6000RPM, what is the rotational delay?– One turn takes 1/6000 min or 1/100 sec = 10ms

– ½ turn takes 5ms.

Page 41: Chapter Goals

41Systems Architecture, Fifth Edition

Average Access Time

• Plus read time (time to spin an entire sector)– If the drive spins at 6000RPM and the disk has 20

sectors per track, what is the read time?

– Time for 1 full spin is

– Time for 1/20 of a spin is

ms10sec100

1min

6000

1

ms5.020

1ms10

Page 42: Chapter Goals

42Systems Architecture, Fifth Edition

Let’s Try Another Problem

• Drive spins at 7200RPM and has average seek time of 8ms. The disk has 24 sectors per track. What is the average access time?

• Head seek time = 0.008 sec (given)

• Rotational delay (1/2 spin) = 7200 RPM (1/2) =

120 RPS(1/2) = 1/120 sec/rev(1/2) = 0.0042 sec

• Read time (1 sector) = 0.0084 (full spin) / 24 sectors per track = 0.00035 sec

• Total = 0.008 + 0.0042 + 0.00035 = 0.01255 sec or 12.55 ms

• This is the average access time

Page 43: Chapter Goals

43Systems Architecture, Fifth Edition

Sequential Access Time

• The best possible read time is if the head is in exactly the right place (like when we read consecutive sectors)

• Sequential access time is the amount of time for one sector to spin under the head

• Drive spins at 7200RPM and has average seek time of 8ms. The disk has 24 sectors per track. What is the sequential access time?

Page 44: Chapter Goals

44Systems Architecture, Fifth Edition

Sequential Access Time

• Drive spins at 7200RPM and has average seek time of 8ms. The disk has 24 sectors per track. What is the sequential access time?

Read time (1 sector) = 0.0084 (full spin) / 24 sectors per track = 0.00035 sec

(no need to include head seek time and rotational delay)

Page 45: Chapter Goals

45Systems Architecture, Fifth Edition

Data Transfer Rate

• The data transfer rate is the number of access that can be made per second times the amount of data per transfer.

• The size of a transfer is the size of a sector, typically 512 bytes.

Page 46: Chapter Goals

46Systems Architecture, Fifth Edition

Maximum Data Transfer Rate

• Maximum data transfer rate is computed using the best possible access time (sequential access time).

• In the prior example, sequential access time was 0.35ms = 0.00035 seconds

• Accesses per second is

• Transfer rate is

1.285700035.0

1

MB/sec4.1bytes 835,462,1bytes 5121.2857

Page 47: Chapter Goals

47Systems Architecture, Fifth Edition

Sustained Data Transfer Rate

• Sustained data transfer rate is computed using the average access time (sectors may not be contiguous).

• In the prior example, average access time was 12.55ms = 0.01255 seconds

• Accesses per second is

• Transfer rate is

68.7901255.0

1

KB/sec40bytes 2.796,40bytes 51268.79

Page 48: Chapter Goals

48Systems Architecture, Fifth Edition

Page 49: Chapter Goals

49Systems Architecture, Fifth Edition

To increase capacity per platter, disk manufacturers divide tracks into zones and vary the sectors per track in each zone.

Page 50: Chapter Goals

50Systems Architecture, Fifth Edition

Optical Mass Storage Devices

• Store bit values as variations in light reflection• Higher areal density and longer data life than

magnetic storage• Standardized and relatively inexpensive• Uses: read-only storage with low performance

requirements, applications with high capacity requirements, and where portability in a standardized format is needed

Page 51: Chapter Goals

51Systems Architecture, Fifth Edition

Optical storage devices read data by shining laser beam on the disc.

Page 52: Chapter Goals

52Systems Architecture, Fifth Edition

Page 53: Chapter Goals

53Systems Architecture, Fifth Edition

CD-ROM

• Read-only; data permanently embedded in durable polycarbonate disc

• Bit values represented as flat areas (lands) and concave dents (pits) in the reflective layer

• Data recorded in single continuous track that spirals outward from center of disc

• Popular medium for distributing software and large data sets

Variable data transfer rate

Page 54: Chapter Goals

54Systems Architecture, Fifth Edition

CD-ROM

Advantages Drawbacks

• Standardized format• High density• Cheap to manufacture

• Cannot be rewritten• Capacity limited to 700

MB

Page 55: Chapter Goals

55Systems Architecture, Fifth Edition

CD-R

• Uses a laser that can be switched between high and low power and a laser-sensitive dye embedded in the disc

• Relatively cheap• Common uses: create music CDs on home

computers, back up data from other storage devices, create archives of large data sets, and manufacture small quantities of identical CDs

Page 56: Chapter Goals

56Systems Architecture, Fifth Edition

Phase-Change Optical Discs

• Enables nondestructive writing to optical storage media

• Materials change state easily from non-crystalline (amorphous), to crystalline, and then back again– Reflective layer is a compound of tellurium,

selenium, and tin

• Example: CD-RW

Page 57: Chapter Goals

57Systems Architecture, Fifth Edition

DVD

• Improves on CD and CD-RW technology– Increased track and bit density: smaller wavelength

lasers and more precise mechanical control

– Improved error correction

– Multiple recording sites and layers

Page 58: Chapter Goals

Flash Drives

• AKA USB flash drives, or UFD• NAND-type flash memory integrated with a USB

connector• Replacing floppy disk/diskette• Lightweight and compact, minimal model contains

a printed circuit board with storage controller device, flash memory chip, crystal oscillator, and LED

58Systems Architecture, Fifth Edition

Page 59: Chapter Goals

Flash Drive Internals

59Systems Architecture, Fifth EditionFrom Wikipedia

Page 60: Chapter Goals

Flash Drive Technology

• Based on earlier EPROM technology (UV-erasable)

• EEPROMs (electrically erasable) replaced EPROMs

• To update contents, an entire “region” of memory has to be moved off the flash drive, updated, the flash drive contents are erased, and the data moved back to the flash drive

60Systems Architecture, Fifth Edition

Page 61: Chapter Goals

Common Uses

• Very popular with network administrators as they load them with configuration information as well as software used for maintenance and recovery

• Operating system boots• Application carriers• MP3 music players• Windows Vista ReadyBoot• And of course file backup

61Systems Architecture, Fifth Edition

Page 62: Chapter Goals

Major Weaknesses

• Limited number of erase and write cycles• Average device should support several hundred

thousand cycles, but write operations will slow with age of device

• Not as fast as fixed disk drives

62Systems Architecture, Fifth Edition

Page 63: Chapter Goals

RAID

• Redundant Array of Independent Drives, is a collection of techniques to interface multiple hard disk drives to a computer

• Mostly, they are a collection of techniques to store data redundantly on multiple hard disk drives

• Only the first RAID technique, RAID 0, does not store the data redundantly

63Systems Architecture, Fifth Edition

Page 64: Chapter Goals

More Common RAID Techniques – RAID 0

• RAID 0, in which the data is broken into pieces and each piece is stored on different disk drives. There is no redundancy of data in this technique, so if one disk drive fails, some of the data is lost. The advantage of this technique is the speed in which data can be read or written across multiple disks at the same time.

• aka striped

64Systems Architecture, Fifth Edition

Page 65: Chapter Goals

65Systems Architecture, Fifth Edition

RAID 0From Wikipedia

Page 66: Chapter Goals

RAID 0

• When two drives are used and they are of different sizes, use the smaller size and double

• For example, one drive is 300 GB and the other is 200 GB, then you have a total of 400 GB of storage

• RAID 0 useful in large, NSF servers (mounting issues) and in Microsoft OS where you might run out of letter designations for drives

66Systems Architecture, Fifth Edition

Page 67: Chapter Goals

RAID 1

• RAID 1, in which the data is stored on at least two disk drives in duplicate so as to provide a level of redundancy (fault tolerance) should one disk become corrupted

• This technique is also known as disk mirroring, or mirrored

67Systems Architecture, Fifth Edition

Page 68: Chapter Goals

68Systems Architecture, Fifth Edition

RAID 1From Wikipedia

Page 69: Chapter Goals

RAID 4

• RAID 4, in which the data is striped across multiple disk drives (based on blocks) and error checking information (parity checks) concerning the stored data is kept along with the data (but on a separate disk).

• This error checking information can be used to detect errors and possibly reconstruct the data should some of it become corrupted.

69Systems Architecture, Fifth Edition

Page 70: Chapter Goals

70Systems Architecture, Fifth Edition

RAID 4From Wikipedia

Page 71: Chapter Goals

RAID 5

• Employs block-level striping with parity information distributed across all data disks

71Systems Architecture, Fifth Edition

Page 72: Chapter Goals

Other RAIDs

• RAID 2 – stripes data at the bit level and uses a Hamming code (no implementations)

• RAID 3 – stripes data at the byte level and uses parity checking

• RAID 6 – block-level striping with two parity blocks spread over all data disks

• And multi-level RAIDs, such as RAID 0-5

72Systems Architecture, Fifth Edition

Page 73: Chapter Goals

73Systems Architecture, Fifth Edition

Summary

• Storage devices and their underlying technologies• Characteristics common to all storage devices• Technology, strengths, and weaknesses of primary

and secondary storage