Newest Viewed Downloaded

Foundations of Computer Science Chapter 5 Computer Organization

Foundations of Computer Science Chapter 5 Computer Organization

Outline

5.1 Central Processing Unit (CPU) 5.2 Main Memory 5.3 Input/Output 5.4 Subsystem Interconnection 5.5 Program Execution 5.6 Two Different Architectures

Computer Hardware (Subsystems)

A computer has three subsystems: the CPU, main memory, and the input/output subsystem.

5.1 Central Processing Unit (CPU)

CPU

The CPU performs operations on data and has an ALU, a control unit, and a set of registers. The ALU performs arithmetic and logical operations The registers are stand-alone storage devices that hold data temporarily Registers can hold data, instructions (指令), and also function as a program counter The control unit oversees operations (監督) in a computer

5.2 Main Memory

Main Memory

Memory units Unit ------------ kilobyte megabyte gigabyte terabyte petabyte exabyte Exact Number of bytes ------------------------ 210 bytes 220 bytes 230 bytes 240 bytes 250 bytes 260 bytes Approximation ------------ 103 bytes 106 bytes 109 bytes 1012 bytes 1015 bytes 1018 bytes Main memory is a collection (大量) of storage locations The total number of uniquely (唯一) identifiable (可識別) locations in memory is called the address space

Main Memory

Because computers operate by storing numbers as bit patterns, the address itself is also represented as a bit pattern Memory addresses are defined using unsigned binary integers

Example

A computer has 32 MB (megabytes) of memory. How many bits are needed to address any single byte in memory? Solution The memory address space is 32 MB, or 225 (25 x 220). This means you need log2 225 or 25 bits, to address each byte.

Example

A computer has 128 MB of memory. Each word in this computer is 8 bytes. How many bits are needed to address any single word in memory? Solution The memory address space is 128 MB, which means 227. However, each word is 8 (23) bytes, which means that you have 224 words. This means you need log2 224 or 24 bits, to address each word.

Memory Types

Two types of memory are available: RAM and ROM RAM provides the bulk (大量) of the memory in a computer, can be read from and written to by the user SRAM uses the traditional flip-flop gates (正反閘) to hold data, and DRAM uses capacitors (電容器) The contents of ROM come from the manufacturer; users are only allowed to read from it, but not write to it Computers need high-speed memory for registers, medium-speed memory for cache memory, and low-speed memory for main memory

Cache

Cache memory is placed between the CPU and main memory. At any time contains a copy of a portion of main memory 80-20rule: It has been observed that most computers typically spend 80% of the time accessing only 20% of the data. In other words, the same data are accessed over and over again

5.3 Input/Output

Input/Output

The input/output subsystem is a collection of devices that allows a computer to communicate with the outside world. These devices are either nonstorage (非儲存性) devices or storage (儲存性) devices The keyboard, monitor, and printer are examples of nonstorage devices A magnetic disk (磁碟) is a storage device

Magnetic (磁性) Storage Device

Magnetic disk (磁碟) Magnetic tap (磁帶)

Magnetic Disk

A magnetic disk (磁碟) is a storage device with each disk in the stack divided into tracks (磁軌) and sectors (磁區)

Physical Layout of a Magnetic Disk

Surface Organization of a Disk

Performance: access time = seek time + rotational time + transfer time

Mechanical Configuration of a Tape

Magnetic tape (磁帶) is a storage device with the tape divided into tracks. Access to the data is sequential (循序).

Surface Organization of a Tape

The width of the type is divided into nine tracks; each spot (點) of a track can store 1 bit of information. Nine vertical spots can store 8 bits of information related to a byte plus a bit for error detection To retrieve a specific block on the tape, you need to pass through all of the previous blocks

Showing 1 - 20 of 51 items Details

Name: 
ch05
Author: 
Shou-Li Hsu
Company: 
N/A
Description: 
Foundations of Computer Science Chapter 5 Computer Organization
Tags: 
the | memory | and | bytes | are | computer | cpu | data
Created: 
9/15/2005 6:07:57 PM
Slides: 
51
Views: 
0
Downloads: 
2
Rating: 
0


> Comment



Share this presentation
|

Comments

Share this presentation:

|
Sitemap