Chapter 1 - Introduction To Computer Architecture and Organization

Download as pdf or txt
Download as pdf or txt
You are on page 1of 21

Computer Architecture and Organization

Chapter I - Introduction-Computer Organization vs Computer Architecture

Learning Outcomes:

At the end of the lesson, you are expected to:

 Compare the difference between Computer Organization from Computer Architecture.


 Discuss and identify the Basic Computer Architecture.
 Identify the function and structure of computer.

What is a Computer?
 A computer is a machine or device that performs processes, calculations and operations
based on instructions provided by a software or hardware program.
 It has the ability to accept data (input), process it, and then produce outputs.
 A fast electronic calculating machine that accepts, digitized input information, processes it
according to a list of internally stored instructions and produces the resultant output
information.

Computer Architecture

Definition
 “The design of integrated system which provides a useful tool to the programmer.” (Baer)
 “The study of the structure, behaviour, and design of computers.” (Hayes)
 “The design of the system specification at a general or subsystem level.” (Abd-Alla)
 “The art of designing a machine that will be a pleasure to work with.” (Foster)
 “The interface between the hardware and the lowest level software.” (Hennessy and
Patterson)

Therefore, computer architecture refers to


 Attributes of a system visible to programmers
 Attributes that have a direct impact on the execution of programs
 Deals with the design of computers, data storage devices, and networking components
that store and run programs, transmit data, and drive interactions between computers,
across networks, and with users.

Computer architecture
 is a specification detailing how a set of software and hardware technology standards
interact to form a computer system or platform.
 refers to how a computer system is designed and what technologies it is compatible with.
 the functional behavior of a computer systems as viewed by a programmer.
 the theory behind the design of a computer.

Attributes of Computer Architecture

o Instruction Set Architecture (ISA)


- the part of the processor that is visible to the programmer or compiler writer.
- serves as the boundary between software and hardware.

o Data representation
- refers to the methods used internally to represent information stored in a computer.
Computers store lots of different types of information: numbers. text.

o I/O mechanisms
- the communication between an information processing system.

o Addressing techniques
1
Computer Architecture and Organization

- are an aspect of the instruction set architecture in most central processing unit (CPU)
designs.

Categories of Computer Architecture

o System Design: This includes all hardware components in the system, including data
processors aside from the CPU, such as the graphics processing unit and direct memory
access. It also includes memory controllers, data paths and miscellaneous things like
multiprocessing and virtualization.

o Instruction Set Architecture (ISA): This is the embedded programming language of the
central processing unit. It defines the CPU's functions and capabilities based on what
programming it can perform or process. This includes the word size, processor register types,
memory addressing modes, data formats and the instruction set that programmers use.

o Microarchitecture: Otherwise known as computer organization, this type of architecture


defines the data paths, data processing and storage elements, as well as how they should
be implemented in the ISA.

Computer Organization

 Refers to operational units and their interconnections that realize the architectural
specifications.
 hardware details transparent to programmers
 involves the studying the major functional units of a computer and how they work

Attributes of Computer Organization

 Control signals
- A pulse or frequency of electricity or light that represents a control command as it
travels over a network, a computer channel or wireless. In the data communications
world, control signals typically travel the same path as the data either as separate
packets or contained within the data packets

 Computer/peripheral interface
o peripheral is a device that is connected to a host computer, but not part of it.
It expands the host's capabilities but does not form part of the core computer
architecture. It is often, but not always, partially or completely dependent on
the host.

o interface is the point of interaction with software, or computer hardware, or


with peripheral devices such as a computer monitor or a keyboard. Some
computer interfaces such as a touch screen can send and receive data,
while others such as a mouse or microphone, can only send data.

There are two types of interfaces:


1. Hardware Interfaces - exist in computing systems between many of the
components such as the various buses, storage devices, other I/O
devices, etc.
2. Software Interfaces - refer to a range of different types of interface at
different "levels": an operating system may interface with pieces of
hardware.

 Memory technology
Modern computer architecture incorporate three principal memory
technologies dominant in supercomputing: DRAM, SRAM, and magnetic
storage media, including hard-disk drives and tapes. A fourth, nonvolatile
random access memory (NVRAM), is emerging as a technology sitting
between DRAM and mass storage.

2
Computer Architecture and Organization

Architecture vs Organization

Computer Architecture: It is concerned with Computer Organization: It is concerned with


structure and behavior of computer interaction with computer

 Architecture - logical design of a computer, allows you to write programs


1. Instruction set (what is the instruction set?)
2. Representation of data types (integers v. characters v. floating point types)
3. Input/Output mechanisms (how does the computer communicate with the world?)
4. Memory addressing techniques

 Organization - physical design of a computer


1. How many registers?
2. What is a register?
3. How many registers does a typical CPU have?

Structure & Function

 Computer
 Complex system=>How can we design/describe it?
 Hierarchic system:
o A set of interrelated subsystems, each subsystem hierarchic in structure until some
lowest level of elementary subsystems is reached
 At each level of the system, the designer is concerned with structure and function.
o Structure is the way in which components relate to each other
o Function is the operation of individual components as part of the structure
Basic computer functions:
 Data processing - refers to the process of collecting and manipulating raw
data to yield useful information.
 Data storage - is a general term for archiving data in electromagnetic or other
forms for use by a computer or device.
 Data movement
• Computer must be able to communicate with outside world
• Data must be “accessible” to devices outside computer
• Two types: – Peripheral – Data communications
 Control
• Something needs to monitor operation and maintain control of data
processing, data storage, and data movement.
• Automated control of computer’s resources

3
Computer Architecture and Organization

The Motherboard

Scientific Prefixes

For computer memory, 1K = 2 10 = 1024. For everything else, like clock speeds, 1K = 1000, and
likewise for 1M, 1G, etc.

Digital Components

Transistors
 Replaced vacuum tubes
 Smaller
 Cheaper
 Less heat dissipation
 Solid State device
 Made from Silicon (Sand)
 Invented 1947 at Bell Labs
 William Shockley et al.

High level digital circuit designs are normally made using collections of logic gates referred to as
components, rather than using individual logic gates. The majority function can be viewed as a
component

Microelectronics
• Literally - “small electronics”
• A computer is made up of gates, memory cells and interconnections
• These can be manufactured on a semiconductor
• e.g. silicon wafer

4
Computer Architecture and Organization

Levels of Integration

Levels of integration (numbers of gates) in an integrated circuit (IC):


• Small scale integration (SSI): 10-100 gates.
• Medium scale integration (MSI): 100 to 1000 gates.
• Large scale integration (LSI): 1000-10,000 logic gates.
• Very large scale integration (VLSI): 10,000-upward.

These levels are approximate, but the distinctions are useful in comparing the relative complexity
of circuits.

Milestone in the development of the modern digital computer

Basic Concepts of Computer Hardware

Primary Memory

Input Output
Units CPU Units
(Central Processing Unit)

* This model of the typical digital computer is often called thevon Neumann computer.
* Programs and data are stored in the same memory: primary memory.
* The computer can only perform one instruction at a time.

5
Computer Architecture and Organization

Computer Components

1. Hardware
– The physical components of the computer system.
– The stuff that you can see, touch and break

2. Software
- The general term given to all programs and the key to productive use of computer.
- The computer program

3. Peopleware
- refer to the user not only a programmer, analyst or encoder. Anybody who operate the
computer.

4. Dataware- refer to data needed to become information

HISTORY

Mechanical machines (before 1930)


During this period, several computing machines were invented that bear little resemblance
to the modern concept of a computer.

 In the 17th century, Blaise Pascal, a French mathematician and philosopher, invented
Pascaline.

 In the late 17th century, a German mathematician called Gottfried Leibnitz invented what
is known as Leibnitz’ Wheel.

 The first machine that used the idea of storage and programming was the Jacquard loom,
invented by Joseph-Marie Jacquard at the beginning of the 19th century.

 In 1823, Charles Babbage invented the Difference Engine. Later ,he invented a machine
called the Analytical Enginethat parallels the idea of modern computers.

 In 1890, Herman Hollerith, working at the US Census Bureau, designed and built a
programmer machine that could automatically read, tally, and sort data stored on
punched cards.

The birth of electronic computers (1930–1950)


Between 1930 and 1950, several computers were invented by scientists who could be
considered the pioneers of the electronic computer industry.

Early electronic computers


The early computers of this period did not store the program in memory—all were
programmed externally. Five computers were prominent during these years:

 ABC
 Z1
 Mark I.
 Colossus
 ENIAC

6
Computer Architecture and Organization

Computers based on the von Neumann model

The first computer based on von Neumann’s ideas was made in 1950 at the University of
Pennsylvania and was called EDVAC(Electronic Discrete Variable Automatic Computer). At the
same time, a similar computer called EDSAC (Electronic Delay Storage Automatic Calculator)was
built by Maurice Wilkes at Cambridge University in England.

Computer generations (1950–present)

Computers built after 1950 more or less follow the von Neumann model. They have become
faster, smaller, and cheaper, but the principle is almost the same. Historians divide this period into
generations, with each generation witnessing some major change in hardware or software (but
not in the model).

First generation

The first generation (roughly 1950–1959) is characterized by the emergence of commercial


computers.

Second generation

Second-generation computers (roughly 1959–1965) used transistors instead of vacuum


tubes. Two high-level programming languages, FORTRAN and COBOL invented and made
programming easier.

Third generation

The invention of the integrated circuit reduced the cost and size of computers even further.
Minicomputers appeared on the market. Canned programs, popularly known as software
packages, became available. This generation lasted roughly from 1965 to 1975.

Fourth generation

The fourth generation (approximately 1975–1985) saw the appearance of microcomputers.


The first desktop calculator, the Altair 8800, became available in 1975. This generation also saw the
emergence of computer networks.

Fifth generation

This open-ended generation started in 1985. It has witnessed the appearance of laptop
and palmtop computers, improvements in secondary storage media (CD-ROM, DVD and so on),
the use of multimedia, and the phenomenon of virtual reality.

Basic Computer Architecture

Computer Components

 Input/output units
 Memory/storage units
 CPU (Central Processing Unit)

7
Computer Architecture and Organization

Motherboard Diagram

8
Computer Architecture and Organization

Motherboard - a printed circuit board containing the principal components of a computer or


other device, with connectors into which other circuit boards can be slotted.

 Northbridge
 is the controller that interconnects the CPU to memory via the frontside bus (FSB). It
also connects peripherals via high-speed channels such as AGP and PCI Express.
 Southbridge
 is one of the two chips in the core logic chipset on a personal computer (PC)
motherboard, the other being the northbridge. The southbridge typically implements
the slower capabilities of the motherboard in a northbridge/southbridge chipset
computer architecture.
 System Bus
 is a pathway composed of cables and connectors used to carry data between a
computer microprocessor and the main memory.
 Related to “omnibus”
 Communication system between components

The system bus connects the CPU with the main memory and, in some systems, with
the level 2 (L2) cache. Other buses, such as the IO buses, branch off from the system bus to
provide a communication channel between the CPU and the other peripherals.

The system bus combines the functions of the three main buses, which are as follows:

 Control bus carries the control, timing and coordination signals to manage the
various functions across the system. (Determines data processing)

 Address bus is used to specify memory locations for the data being transferred.
(Determines where data should be sent)

 Data bus which is a bidirectional path carries the actual data between the
processor, the memory and the peripherals. (Carries the data that needs processing)

Computer System

9
Computer Architecture and Organization

Connection of Components

10
Computer Architecture and Organization

CPU Architecture

Computer architecture is a specification detailing how a set of software and hardware


technology standards interact to form a computer system or platform. In short, computer
architecture refers to how a computer system is designed and what technologies it is compatible
with.

As with other contexts and meanings of the word architecture, computer architecture is
likened to the art of determining the needs of the user/system/technology, and creating a logical
design and standards based on those requirements.

Turing Model and Von Neuman Model

Turing Model

The idea of a universal computational device was first described by Alan Turing in 1937. He
proposed that all computation could be performed by a special kind of a machine, now called a
Turing machine. He based the model on the actions that people perform when involved in
computation. He abstracted these actions into a model for a computational machine that has
really changed the world.

Data processors

Before discussing the Turing model, let us define a computer as a data processor. Using this
definition, a computer acts as a black box that accepts input data, processes the data, and
creates output data (Figure 1.1). Although this model can define the functionality of a computer
today, it is too general. In this model, a pocket calculator is also a computer (which it is, in a literal
sense)

Figure 1.1 A single purpose computing machine

Programmable data processors

The Turing model is a better model for a general-purpose computer. This model adds an
extra element to the specific computing machine: the program. A program is a set of instructions
that tells the computer what to do with data. Figure shows the Turing model.

11
Computer Architecture and Organization

Figure 1.2 A computer based on the Turing model

Figure1.3 The same program, different data

Figure 1.4 The same data, different programs

The universal Turing machine

A universal Turing machine, a machine that can do any computation if the appropriate
program is provided, was the first description of a modern computer. It can be proved that a very
powerful computer and a universal Turing machine can compute the same thing. We need only
provide the data and the program—the description of how to do the computation—to either
machine. In fact, a universal Turing machineis capable of computing anything that is computable.

A Turing machine is a mathematical model of computation that defines an abstract machine,


which manipulates symbols on a strip of tape according to a table of rules. The Turing
machine was invented in 1936 by Alan Turing, who called it an a-machine(automatic machine).

Turing machine?

 has a two-way infinite tape, made of


cells. In each cell, there is a symbol.
 has a tape head. With this tape
head, the machine can read and
write on the tape.
 has a finite number of states.
12
Computer Architecture and Organization

 has a next move function.

Von Neumann Model

Computers built on the Turing universal machine store data in their memory. Around 1944–
1945, John von Neumann proposed that, since program and data are logically the same,
programs should also be stored in the memory of a computer.

Four subsystems

Computers built on the von Neumann model divide the computer hardware into four
subsystems: memory, arithmetic logic unit, control unit, and input/output (Figure).

Figure: The von Neumann model

The Stored Program Concept

The von Neumann model states that the program must be stored in memory. This is totally
different from the architecture of early computers in which only the data was stored in memory:
the programs for their task was implemented by manipulating a set of switches or by changing the
wiring system.
The memory of modern computers hosts both a program and its corresponding data. This
implies that both the data and programs should have the same format, because they are stored
in memory. In fact, they are stored as binary patterns in memory—a sequence of 0s and 1s.

Sequential Execution of Instructions

A program in the von Neumann model is made of a finite number of instructions. In this
model, the control unit fetches one instruction from memory, decodes it, thenexecutes it. In other
words, the instructions are executed one after another. Of course, one instruction may request the
control unit to jump to some previous or following instruction, but this does not mean that the
instructions are not executed sequentially. Sequential execution of a program was the initial
requirement of a computer based on the von Neumann model. Today’s computers execute
programs in the order that is the most efficient.

Functional View of the The von Neumann Model

The von Neumann model consists of five major components:


(1) input unit; (2) output unit; (3) arithmetic logic unit; (4) memory unit; (5) control unit.

13
Computer Architecture and Organization

A very good example of computer architecture is von Neumann architecture, which is still used by
most types of computers today. This was proposed by the mathematician John von Neumann in
1945. It describes the design of an electronic computer with its CPU, which includes the arithmetic
logic unit, control unit, registers, memory for data and instructions, an input/output interface and
external storage functions

The Von Neumann model in the year 2004

The von Neumann architecture, which is also known as the von Neumann model and Princeton
architecture, is a computer architecture based on the 1945 description by the mathematician and
physicist John von Neumann and others in the First Draft of a Report on the EDVAC.

Von Neumann computer systems contain three main building blocks:


 the central processing unit (CPU),
 memory,
 and input/output devices (I/O).

These three components are connected together using the system bus.The most prominent items
within the CPU are the registers: they can be manipulated directly by a computer program.

The System Bus Model

 A refinement of the von Neumann model, the system bus model has a CPU (ALU and
control), memory, and an input/output unit.
 Communication among components is handled by a shared pathway called the system
bus, which is made up of the data bus, the address bus, and the control bus. There is also a
power bus, and some architectures may also have a separate I/O bus.

14
Computer Architecture and Organization

Data bus - is a system within a computer or device, consisting of a connector or set of wires, that
provides transportation for data.

address bus - is a computer bus architecture used to transfer data between devices that are
identified by the hardware address of the physical memory (the physical address), which
is stored in the form of binary numbers to enable the data bus to access memory
storage.

Control bus - is a computer bus that is used by the CPU to communicate with devices that are
contained within the computer. This occurs through physical connections such as cables
or printed circuits.

Peripheral bus. Also known as an "input/output bus" or "I/O bus," it is the data pathway that
connects peripheral devices to the CPU. The PCI and USB busses are commonly used in
PCs. ISA, EISA, VL-bus and Micro Channel busses were used in earlier PCs.

The following block diagram shows major relationship between CPU components:

15
Computer Architecture and Organization

Components of the Von Neumann Model

 Memory: Storage of information (data/program)


 Processing Unit: Computation/Processing of Information
 Input: Means of getting information into the computer. e.g. keyboard, mouse
 Output: Means of getting information out of the computer. e.g. printer, monitor
 Control Unit: Makes sure that all the other parts perform their tasks correctly and at the
correct time.

The main feature of the Turing or von Neumann models is the concept of the program.
Although early computers did not store the program in the computer’s memory, they did use the
concept of programs. Programming those early computers meant changing the wiring systems or
turning a set of switches on or off. Programming was therefore a task done by an operator or
engineer before the actual data processing began.

Figure: Program and data in memory

Figure: A program made of instructions

16
Computer Architecture and Organization

von Neumann Architecture

Harvard Architecture
- is a computer architecture with physically separate storage and signal pathways for
instructions and data.
- the term originated from the Harvard Mark I relay-based computer, which stored
instructions on punched tape (24 bits wide) and data in electro-mechanical counters.

Machine Cycle

 Fetch-decode-execute-store

Fetch: The Fetch Operation is used for taking the instructions those are given by the
user and the Instructions those are stored into the Main Memory will be fetch
by using Registers.

Decode: The Decode Operation is used for interpreting the Instructions means the
Instructions are decoded means the CPU will find out which Operation is to be
performed on the Instructions.

17
Computer Architecture and Organization

Execute: The Execute Operation is performed by the CPU. And Results those are
produced by the CPU are then Stored into the Memory and after that they
are displayed on the user Screen.

Concept of Registers

 Small, permanent storage locations within the CPU used for a particular purpose
 Manipulated directly by the CU
 Wired for specific function
 Size in bits or bytes (not MB like memory)
 Can hold data, an address or an instruction

Register Operations

 Stores values from other locations (registers and memory)


 Addition and subtraction
 Shift or rotate data
 Test contents for conditions such as zero or positive

Cache Memory
- is the fastest memory in a computer. It is typically integrated on the motherboard and
directly embedded on the processor or main random access memory (RAM).
- is a small-sized type of volatile computer memory that provides high-speed data access
to a processor and stores frequently used computer programs, applications and data.
- It stores and retains data only until a computer is powered up.

 Cache level
 L1 cache: fastest and smallest
o is a memory cache that is directly built into the microprocessor, which is used for
storing the microprocessor’s recently accessed information, thus it is also called
the primary cache. It is also referred to as the internal cache or system cache.
 L2 cache: next fastest and smallest
o is a CPU cache memory that is located outside and separate from the
microprocessor chip core, although, it is found on the same processor chip
package. Earlier L2 cache designs placed them on the motherboard which
made them quite slow.

Operation of Memory

 Each memory location has a unique address


 Address from an instruction is copied to the MAR (Memory Address Register) which finds the
location in memory
 CPU determines if it is a store or retrieval
 Transfer takes place between the MDR (Memory Data Register) and memory
 MDR is a two way register

18
Computer Architecture and Organization

MAR, MDR, Memory

MAR-MDR Example

Individual Memory Cell

Memory - refers to any information or data, often in binary format, that a machine or technology
can recall and use.

Memory Capacity

Determined by two factors :

1. Number of bits in the MAR


 2K where K = width of the register in bits
2. Size of the address portion of the instruction
 4 bits allows 16 locations
 8 bits allows 256 locations
 32 bits allows 4,294,967,296 or 4 GB
 Important for performance
 Insufficient memory can cause a processor to work at 50% below performance

19
Computer Architecture and Organization

Random Access Memory


 DRAM (Dynamic RAM)
 Most common, cheap
 Volatile: must be refreshed (recharged with power) 1000’s of times each second
 SRAM (Static RAM)
 Faster than DRAM and more expensive than DRAM
 Volatile
 Frequently small amount used in cache memory for high-speed access used

Read Only Memory


 Non-volatile memory to hold software that is not expected to change over the life of the
system
 Magnetic core memory
 EEPROM
 Electrically Erasable Programmable ROM
 Slower and less flexible than Flash ROM
 Flash ROM
 Faster than disks but more expensive
 Uses
 BIOS: initial boot instructions and diagnostics
 Digital cameras

CMOS Memory

CMOS (Complimentary Metal Oxide Semiconductor)


- is an on-board, battery powered semiconductor chip inside computers that stores
information.

BIOS (basic input/output system)


 is the program a personal computer's microprocessor uses to get the computer system
started after you turn it on.
 It also manages data flow between the computer's operating system and attached
devices such as the hard disk, video adapter, keyboard, mouse and printer.
 is a preinstalled program used during startup on Windows-based computers. The CPU
initially accesses the BIOS, after which the operating system is loaded.
 is also known as system BIOS or ROM BIOS.

The BIOS is built-in software that contains generic code required to control the keyboard, display
screens, disk drives and other functions. The primary purpose of the BIOS is to set up hardware and
further load and start an operating system. BIOS is placed in a nonvolatile ROM chip inside the
computer, ensuring the availability of BIOS at all times and preventing accidental disk failure. The
BIOS checks every hardware connection and locates the devices, after which the operating
system is loaded into computer memory.

BIOS software is designed to work with the various devices that make up a complimentary system
chipset. The BIOS library has certain functions used to operate and control system peripherals,
which can be initiated by an external software.

Users using the BIOS user interface can perform functions such as:
 Setting the system clock
 Enabling and disabling certain system components
 Hardware configuration
 Selecting boot drives
 Set password prompts for secured access to BIOS user interface function

20
Computer Architecture and Organization

 Modern PCs have BIOS stored in rewritable memory, permitting contents to be rewritten or
replaced. Such content rewriting is called flashing and is executed through a special
program provided by system manufacturers.

Assessment Task

Answer the following:

1. What is the distinction between computer organization and computer architecture?

2. What is the distinction between computer structure and computer function?

3. What are the main functions of a computer?

4. List and briefly define the main structural components of a computer.

5. List and briefly define the main structural components of a processor.

References :

“Computer Organization and Design:The Hardware/Software Interface” by David A Patterson and John L
Hennessy
“Computer Organization” by Zvonco Vranesic and Safwat Zaky
“Computer Architecture and Organization” by John P Hayes
“Computer Organization and Architecture: Designing for Performance” by William Stallings
“Computer Systems Design and Architecture” by Vincent P Heuring and Harry F Jordan
“Computer Architecture & Organization” by Raj Kamal and Nicholas Carter
“Computer Organization and Design” by John L Hennessy David
“Computer Organization and Architecture” by William Stallings
“Computer Architecture and Organization : From 8085 to core2Duo & beyond” by Ghoshal
“Computer Organization & Architecture” by Stallings

21

You might also like