Slides from Chapter 1
Download
Report
Transcript Slides from Chapter 1
DRAM capacity
1000M ~2004
1000
512M
256M
100
Mbit capacity
64M
10
16M
1M
1
64K
0.1
4M
256K
15K
0.01
0.001
1976
1978
1980
1982
1984
1986
1988
1990
1992
1994
1996
Hardware Computer Organization for the Software Professional
Arnold S. Berger
1998
2000
1
Abstract view of a computer
Hardware Computer Organization for the Software Professional
Arnold S. Berger
2
Abstraction layers
Hardware Computer Organization for the Software Professional
Arnold S. Berger
3
Memory hierarchy
•
•
•
There is a hierarchy of memory
In order to maximize processor throughput, the fastest memory is closest to
the processor
Primary Cache
- Also the most expensive
CPU
2K- 1,024K byte (<1ns)
Notice:
- The exponential rise in capacity
Bus Interface Unit
with each layer
- The exponential rise in access time
Secondary Cache
256K
- 4MByte (10ns)
in each layer
Main Memory
1M – 2 Gbyte (30 ns)
Hard Disk
40 - 250 GByte ( 100,000 ) ns
Tape Backup
50G - 10TByte (seconds)
Internet
All knowledge/Forever
Hardware Computer Organization for the Software Professional
Arnold S. Berger
4
Hard disk drive
Hardware Computer Organization for the Software Professional
Arnold S. Berger
5
Representing a number as a voltage
• Represent the data value as a voltage or current along a single
electrical conductor (signal trace) or wire
24.56345
RADIO
SHACK
24.56345 V
Direction of signal
• Problems:
• Measuring large numbers is difficult, slow and expensive
• How do you represent +/- 32,673,102,093?
Hardware Computer Organization for the Software Professional
Arnold S. Berger
Zero volts
(ground)
6
Parallel transmission of 0 to 9
• Represent the data value as a voltage or current along multiple
electrical conductors
•Let each wire represent one decade of the number
• Only need to divide up the voltage on each wire into 10 steps
• 0 V to 9 volts
• Can have considerable “slop” between values before it causes
problems
4.2
RADIO
SHACK
2
4
5
6
3
4
5
Zero volts
(ground)
Hardware Computer Organization for the Software Professional
Arnold S. Berger
7
Binary data transmission
• Represent the data value as a voltage or current along multiple, parallel,
electrical conductors
•Let each wire represent one power of 2 of the number ( 20 through 2N )
• Only need to divide up the voltage on each wire into 2 possible steps
• 0 V “no volts” or “some volts” greater than zero (on or off )
• Can have lots of “slop” between values
20
21
22
23
24
25
26
27
28
29
210
211
212
213
214
215
Hardware Computer Organization for the Software Professional
Arnold S. Berger
on
off
on
off
off
on
on
on
off
off
off
on
on
on
on
off
1
0
1
0
0
1
1
1
0
0
0
1
1
1
1
0
8
A simple AND circuit
•
•
•
Digital computers force us to deal with number systems other than decimal
- ALL digital computers are collections of switches made from transistors
- A switch is ON or OFF
- A binary (digital) system lends itself to using electronic on/off switching
Principles of Logic (a branch of Philosophy ) are useful to describe the
digital circuits in computers
- True/False, 1/0, On/OFF, High/Low all describe the same possible states
of a digital system
An electrical circuit, with ordinary switches, is a convenient display
on/off switch
A
+
B
C
C = A and B
Battery Symbol
-
Light bulb (load)
Hardware Computer Organization for the Software Professional
Arnold S. Berger
9
Decimal representation
•
•
•
•
Writing a number is the same in all number systems
Each column of the number represents the base that the number is raised
to
Example: 65,53610 = 216
104
103
102
101
100
6
5
5
3
6
Notice how each column is weighted by
the value of the base raised to the power
+
6 x 100 =
6
3 x 101 =
30
5 x 102 =
500
5 x 103 =
5000
6 x 104 =
60000
=
65536
Hardware Computer Organization for the Software Professional
Arnold S. Berger
10
Binary numbers
•
•
Just like decimal numbers, binary numbers are represented as the power of
the base:
Example: 10101100
Bases of Hex and Octal
B
1
0
1
0
1
1
0
0
x 27
x 26
x 25
x 24
x 23
x 22
x 21
x 20
= 128
=
0
= 32
=
0
=
8
=
4
=
0
=
0
128
64
32
16
8
4
2
1
27
26
25
24
23
22
21
20
1
0
1
0
1
1
0
0
10101100
2
=
172
10
172
Hardware Computer Organization for the Software Professional
Arnold S. Berger
11
Binary and octal numbers
•
•
Let’s look at our example again:
Notice that because 8 = 23 we can easily convert binary to octal
- Just group columns of three and treat as binary within a column to get
octal number from 0 to 7
82
81
80
128
64
32
16
8
4
2
1
27
26
25
24
23
22
21
20
26 (21
1
20 )
0
0 thru 192
23( 22
1
21
0
0 thru 56
20)
1
20 ( 22
1
21
0
4 x 80 = 4
5 x 81 = 40
2 x 82 = 128
172
20)
0
0 thru 7
Hardware Computer Organization for the Software Professional
Arnold S. Berger
12
Binary and hex
•
•
Hexadecimal is the same principle as octal
- Hexadecimal is the most common number system in computer science
- Octal was common with minicomputers but is now a special function
counting system
Back to our example: 10 x 16 + 12 x 1 = 172 = AC (Hex)
161
128
64
160
32
16
8
4
2
1
22
21
20
27
26
25
24
23
24(23
22
21
20)
20 ( 23
1
0
1
0
1
22
21
20)
1
0
0
Hardware Computer Organization for the Software Professional
Arnold S. Berger
13
Bits, bytes, nibbles, words, etc.
Bit (1)
D3
D0
Nibble (4)
D7
D0
Byte (8)
D15
D31
D0
Word (16)
D0
Long (32)
D63
D0
Double (64)
D127
D0
VLIW (128)
Hardware Computer Organization for the Software Professional
Arnold S. Berger
14
A Seven Segment Display using BCD
0000
0001
0010
0011
0101
0100
carry
the
one
0110
0111
1000
1001
0001
Hardware Computer Organization for the Software Professional
Arnold S. Berger
0000
15