Fundamentals of Computer Organisation and Architecture Computer Science

  • Slides: 33
Download presentation
Fundamentals of Computer Organisation and Architecture Computer Science

Fundamentals of Computer Organisation and Architecture Computer Science

The Basic Computer Model • Computers can do different things based on what they

The Basic Computer Model • Computers can do different things based on what they were made for Calculators calculate values Tills record and calculate money totals • However, computers have evolved over time Originally just for number crunching Now can do lots of different things • We’re going to look at what a computer is, what a computer can do, and what a computer contains 2 Fundamentals of Computer Organisation and Architecture: Computer Architecture

The Basic Computer Model • Before going in-depth with these, we need to know

The Basic Computer Model • Before going in-depth with these, we need to know one thing Different ‘computers’ can do different things • There’s a simple way to break this down The Input-Process-Output model Input 3 Process Fundamentals of Computer Organisation and Architecture: Computer Architecture Output

Computer Components • More specifically, computers use – Three Box Model • Core requirements

Computer Components • More specifically, computers use – Three Box Model • Core requirements of a Computer Central Processing Unit Think Remember Communicate Bus Processor 4 Main Memory I/O Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components Central Processing Unit (CPU, a. k. a. Processor) • Considered to be

Computer Components Central Processing Unit (CPU, a. k. a. Processor) • Considered to be the brain of the computer • Is a single, small chip (that can be quite fragile) • Responsible for executing programs, performing basic operations, and supervising other components 5 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components Main Memory (IAS) • Immediate Access Store (IAS) – Stores Machine Code

Computer Components Main Memory (IAS) • Immediate Access Store (IAS) – Stores Machine Code • Sequences of code stored in Addresses – Program Instructions – Data • One or more Integrated Circuits – Directly addressable unique locations by processor – Memory Location = Separately addressable – Multiple Memory Chips (512 KB to 2 Gb) – 1 Address = 1 Byte = 8 bits RAM ROM EEPROM 6 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components Main Memory (RAM, ROM, EEPROM) • Stores temporary/permanent data Values for a

Computer Components Main Memory (RAM, ROM, EEPROM) • Stores temporary/permanent data Values for a program Machine code that will be executed on the CPU • Accessed via addresses (binary numbers determined by CPU architecture) • Comes in different types, chip sizes (both memory and physical size), and different speeds 7 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components Main Memory (RAM, ROM, EEPROM) • RAM – Random Access Memory •

Computer Components Main Memory (RAM, ROM, EEPROM) • RAM – Random Access Memory • Writable and readable stores for data But volatile • RAM addresses are temporary, and only store data while the computer is powered on 8 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components Main Memory (RAM, ROM, EEPROM) • RAM can be found in a

Computer Components Main Memory (RAM, ROM, EEPROM) • RAM can be found in a few places ‘Sticks’ of RAM for general data storage CPU can have a cache as well • Caches are fast-access RAM stores used mostly by the CPU • Allows the CPU to store frequently references data (like program instructions) Can speed up process time over storing this data in usual RAM 9 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components Main Memory (RAM, ROM, EEPROM) • ROM – Read Only Memory •

Computer Components Main Memory (RAM, ROM, EEPROM) • ROM – Read Only Memory • Readable only Contains pre-made data/programs • Often used to store a program that boots the operating system on the computer 10 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components Main Memory (RAM, ROM, EEPROM) • EEPROM – Electrically Erasable Programmable Read

Computer Components Main Memory (RAM, ROM, EEPROM) • EEPROM – Electrically Erasable Programmable Read Only Memory • Writable and readable, and non-volatile Data is permanently stored until overwritten or destroyed Writing over 100 times slower than reading from • Flash Memory faster at writing than other types of EEPROM Blocks of bytes must be erased and written in one go rather than individual bytes • Comes in lots of different formats Examples include USB sticks, SD cards, and Solid-State Drives 11 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components EEPROM Flash Memory Mobile phone SIM Card Digital Camera MP 3 player

Computer Components EEPROM Flash Memory Mobile phone SIM Card Digital Camera MP 3 player PDA 12 Memory stick / Card Medical Electronics Solid State Drives Synthesisers Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components • The System Bus – – External Bus also exists Transmits binary

Computer Components • The System Bus – – External Bus also exists Transmits binary word between processor & store or I/O component Collection of signals which act together Set of parallel wires connect independent components to pass signals Three Buses Data Address Control 13 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components • Bus – Set of parallel of wires January 1989 Motorola 68030

Computer Components • Bus – Set of parallel of wires January 1989 Motorola 68030 16 MHz Processor with: 32 -bit internal registers, a 24 -bit address bus, and a 16 -bit data bus -http: //www. theregister. co. uk/2010/11/09/macintosh_portable/page 6. html 14 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components • Three buses – Data Bus • Bidirectional • 32 0 r

Computer Components • Three buses – Data Bus • Bidirectional • 32 0 r 64 Wires • Transports data – Address Bus • Unidirectional • 32 or 64 Wires • Signals from Processor address Memory and I/O – Control Bus • • • 15 Bidirectional 8 Wires Transports command signals Checks presence and condition of components Specifies timing and direction of data flow Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components • Control bus signals – Signals Transmitted • Clock Signal – Digital

Computer Components • Control bus signals – Signals Transmitted • Clock Signal – Digital tick (metronome) for timing purposes • Reset Signal – Used to initialise (wake) components before use • Memory Read – Asserts current memory location is being read from • Memory Write – Asserts current memory location is being written to • I/O – I/O and main memory occasionally share memory addresses – Asserts wish to use an I/O controller not main memory 16 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components • Buses – Address Bus • Address used to specify a memory

Computer Components • Buses – Address Bus • Address used to specify a memory location – – E. g. 32 -bit address needs 32 binary signals to specify location Signals are lumped together and called the “address bus” 16 -bits wide in ‘small’ processors / microcontrollers 32 -bits & 64 bits wide in PCs, workstations, etc. – Data Bus • Data transfers – Same width as Processor registers / ALU – Narrower reduces costs (pins, wiring, memory devices) – Wider increases bandwidth (fetch two instructions in one cycle) » Bandwidth is rate at which data is transferred – Double Bandwidth • Cycle Bus at twice the speed • Double number of bits 17 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components - Bus • Buses – Address Bus • Address used to specify

Computer Components - Bus • Buses – Address Bus • Address used to specify a memory location – – E. g. 32 -bit address needs 32 binary signals to specify location Signals are lumped together and called the “address bus” 16 -bits wide in ‘small’ processors / microcontrollers 32 -bits & 64 bits wide in PCs, workstations, etc. – Data Bus • Data transfers – Same width as Processor registers / ALU – Narrower reduces costs (pins, wiring, memory devices) – Wider increases bandwidth (fetch two instructions in one cycle) » Bandwidth is rate at which data is transferred – Double Bandwidth • Cycle Bus at twice the speed • Double number of bits 18 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components Input/Output Devices • Help the user use a computer • Input devices

Computer Components Input/Output Devices • Help the user use a computer • Input devices let the user interact with the computer Mouse and Keyboard Microphone • Output devices let the computer show results/data to the user Monitor Speakers 19 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components Input/Output Devices • Controls data flow – CPU Peripherals – Peripherals not

Computer Components Input/Output Devices • Controls data flow – CPU Peripherals – Peripherals not directly connected to Processor • Every new Peripheral would require redesign of Processor – I/O Controllers • • 20 Interface and translator for each Peripheral Specific I/O Controller for specific Peripheral device Reduced signal speed Operate as unidirectional (input / output only), or Bidirectional Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components I/O Controllers • Three Parts • Electronic interface between controller and System

Computer Components I/O Controllers • Three Parts • Electronic interface between controller and System Bus • I/O port – set of registers for data, commands and status • Written to / Read From • Data Exchange – Processor Peripheral • Necessary electronics for sending control signals to connected peripherals 21 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components Central Processing Unit Processor Main Memory / (IAS) Keyboard Input Controller VDU

Computer Components Central Processing Unit Processor Main Memory / (IAS) Keyboard Input Controller VDU Output Controller VDU (Disk) I/O Controller Secondary Store / Backing Store CPU communicates with peripheral devices through special communication tunnels (I/O controllers) 22 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Computer Components Expanded three box model • Signal Transmissions – Which Direction? – What

Computer Components Expanded three box model • Signal Transmissions – Which Direction? – What is being transmitted? CONTROL BUS KEYBOARD CONTROLLER MAIN MEMORY PROCESSOR ADDRESS BUS DATA BUS 23 Fundamentals of Computer Organisation and Architecture: Computer Architecture VDU CONTROLLER MAGNETIC DISK CONTROLLER

Computer Components Secondary Storage (Hard-Disk Drives and Solid-State Drives) • Used to store permanent

Computer Components Secondary Storage (Hard-Disk Drives and Solid-State Drives) • Used to store permanent data on the computer The operating system Installed programs Day-to-day files • Slower at being accessed than Main Memory • Examples include Hard-Disk Drives Solid-State Drives 24 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Fixed Program Computers • Pre-1945 – Punch Card Operations – Fixed programs – hard-coded

Fixed Program Computers • Pre-1945 – Punch Card Operations – Fixed programs – hard-coded – Changes took days or weeks • ENIAC took three weeks to rewire and rebuild (Electronic Numerical Integrator And Computer) • Modern day Fixed program Computers Tools Calculator, Central Heating, Programmable Microwave Games Pac. Man, Tamagochi 25 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Von Neumann Architecture • Von Neumann – Hungarian Mathematician – Contemporary of Albert Einstein

Von Neumann Architecture • Von Neumann – Hungarian Mathematician – Contemporary of Albert Einstein – Principal Member of the Manhattan Project • Post-1945 – Von Neumann Architecture – Stored Program Concept – Programs inside Computer NOT hardcoded – Registers hold instructions and data semi-permanently • Stored for repeated use • Deleted / Replaced as required 26 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Stored program concept • Program must be resident in main memory to be executed

Stored program concept • Program must be resident in main memory to be executed • Machine code instructions – – – are fetched one after another from main memory in sequence and are executed one at a time in the processor First Stored Program 1948 – SSEM (Baby) CRT Output 27 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Stored program concept • Processor instructed to perform arithmetic and logical operations ADD, SUBTRACT,

Stored program concept • Processor instructed to perform arithmetic and logical operations ADD, SUBTRACT, AND, OR • Instructions represented by Binary / Machine Code – Instructions and data stored in same way – Bit pattern 01000110 could be • number 4616 • letter F • Instruct Processor to perform addition 28 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Stored program concept • Von Neumann Stored Program Concept • A serial machine –

Stored program concept • Von Neumann Stored Program Concept • A serial machine – Instructions and data fetched in sequence, one at a time – Single shared memory • Program instructions and Data – Shared Data Bus • Program Instructions and Data Addresses Processor Main Memory Data and Instructions 29 Fundamentals of Computer Organisation and Architecture: Computer Architecture

Stored program concept • Harvard Stored Program Concept • Dual Serial Machine – Instructions

Stored program concept • Harvard Stored Program Concept • Dual Serial Machine – Instructions and data fetched in sequence • Separate Memory – Instruction – Data • Separate Data Bus – Instruction – Data • Serial and Parallel Instruction Memory – Instructions fetched serially – Data fetched serially – Instructions and Data fetched in parallel 30 Instruction Address Processor Instruction Fundamentals of Computer Organisation and Architecture: Computer Architecture Data Address Read/Write Data Memory

Von Neumann versus Harvard • Von Neumann architecture – Instruction and data shares the

Von Neumann versus Harvard • Von Neumann architecture – Instruction and data shares the same bus – Compete for resources Processor Addresses Main Memory Data and Instructions • Harvard architecture – No competition – Instruction fetches and reading and writing of data take place in parallel – Increases overall processing speed Instruction Memory 31 Instruction Address Processor Instruction Fundamentals of Computer Organisation and Architecture: Computer Architecture Data Address Read/Write Data Memory

Von Neumann versus Harvard • Embedded system – – Use Harvard architecture Special-purpose computer

Von Neumann versus Harvard • Embedded system – – Use Harvard architecture Special-purpose computer system Devices using embedded system Digital Cameras, Cars, Domestic appliances and many more Built into another device Performs few dedicated functions • General-purpose computer (personal computer) – Von Neumann Architecture – Programmed and reprogrammed – Perform many different tasks 32 Fundamentals of Computer Organisation and Architecture: Computer Architecture