Computer Architecture Lecture 03 Fasih ur Rehman.

Slides:



Advertisements
Similar presentations
The CPU The Central Presentation Unit What is the CPU?
Advertisements

Computer Architecture
Instruction Set Design
Topics covered: CPU Architecture CSE 243: Introduction to Computer Architecture and Hardware/Software Interface.
Computer Organization and Architecture
Chapter 12 CPU Structure and Function. CPU Sequence Fetch instructions Interpret instructions Fetch data Process data Write data.
Computer Organization and Architecture
Computer Organization and Architecture
Room: E-3-31 Phone: Dr Masri Ayob TK 2123 COMPUTER ORGANISATION & ARCHITECTURE Lecture 5: CPU and Memory.
Computer Systems. Computer System Components Computer Networks.
Execution of an instruction
Memory - Registers Instruction Sets
Chapter 4 Processor Technology and Architecture. Chapter goals Describe CPU instruction and execution cycles Explain how primitive CPU instructions are.
Topics covered: ARM Instruction Set Architecture CSE 243: Introduction to Computer Architecture and Hardware/Software Interface.
Chapter 7. Basic Processing Unit
Dale & Lewis Chapter 5 Computing components. Let’s design a computer Generic CPU with registers −Program counter (PC) – 5 bits (size of addresses) −Instruction.
Group 5 Alain J. Percial Paula A. Ortiz Francis X. Ruiz.
CH12 CPU Structure and Function
Processor Organization and Architecture Module III.
Basic Operational Concepts of a Computer
Chapter 4 The Von Neumann Model
Computer Architecture Lecture 09 Fasih ur Rehman.
Chapter 2-2 Assembly Instructions Number Systems Number Systems Assembly Instructions Assembly Instructions Branch Branch Next Lecture Next Lecture  Addressing.
Model Computer CPU Arithmetic Logic Unit Control Unit Memory Unit
Execution of an instruction
Lecture 14 Today’s topics MARIE Architecture Registers Buses
DH2T 34 – HNC Computer Architecture 1 Lecture 14 The Fetch-Decode-Execute Cycle [1]. © C Nyssen/Aberdeen College 2003 All images © C Nyssen/Aberdeen College.
Fetch-execute cycle.
D75P 34 – HNC Computer Architecture
In1210/01-PDS 1 TU-Delft Instructions and addressing.
Computer Organization 1 Instruction Fetch and Execute.
The von Neumann Model – Chapter 4 COMP 2620 Dr. James Money COMP
COMPUTER ORGANISATION Sri.S.A.Hariprasad Sr.Lecturer R.V.C.E Bangalore.
Dale & Lewis Chapter 5 Computing components
COMPUTER ORGANIZATION AND ASSEMBLY LANGUAGE Lecture 21 & 22 Processor Organization Register Organization Course Instructor: Engr. Aisha Danish.
Processor Structure and Function Chapter8:. CPU Structure  CPU must:  Fetch instructions –Read instruction from memory  Interpret instructions –Instruction.
Computer Architecture Lecture 15 Fasih ur Rehman.
Von Neumann Model Computer Organization I 1 September 2009 © McQuain, Feng & Ribbens The Stored Program Computer 1945: John von Neumann –
Computer Architecture Lecture 5 by Engineer A. Lecturer Aymen Hasan AlAwady 25/11/2013 University of Kufa - Informatics Center for Research and Rehabilitation.
Question What technology differentiates the different stages a computer had gone through from generation 1 to present?
Computer Architecture Lecture 4 by Engineer A. Lecturer Aymen Hasan AlAwady 17/11/2013 University of Kufa - Informatics Center for Research and Rehabilitation.
Processor Organization
Structure and Role of a Processor
Computer Organization Instructions Language of The Computer (MIPS) 2.
1 Computer Architecture. 2 Basic Elements Processor Main Memory –volatile –referred to as real memory or primary memory I/O modules –secondary memory.
8085 INTERNAL ARCHITECTURE.  Upon completing this topic, you should be able to: State all the register available in the 8085 microprocessor and explain.
Lec 4-2 Five operations of the machine cycle Fetch- fetch the next program instruction from memory. (PC+1); instruction to IR Decode- decode the instruction.
1 CSCI 2510 Computer Organization Memory Addressing and Assembly Instruction Basics.
COMPUTER ORGANIZATION UNIT 1. COMPUTER ORGANISATION AND ARCHITECTURE The components from which computers are built, i.e., computer organization. In contrast,
Chapter 4 The Von Neumann Model
Microcomputer Programming
Computer Organization and Assembly Language (COAL)
Chapter 4 The Von Neumann Model
Processor Organization and Architecture
Basic Processing Unit Unit- 7 Engineered for Tomorrow CSE, MVJCE.
Functional Units.
Computer Organization and ASSEMBLY LANGUAGE
Topic 6 LC-3.
MARIE: An Introduction to a Simple Computer
ECEG-3202 Computer Architecture and Organization
Computer Architecture and the Fetch-Execute Cycle
Computer Architecture
Fundamental Concepts Processor fetches one instruction at a time and perform the operation specified. Instructions are fetched from successive memory locations.
Basic components Instruction processing
CPU Structure and Function
Presentation transcript:

Computer Architecture Lecture 03 Fasih ur Rehman

Last Class Bus Organization Operational Concepts of a Computer Software (System/Application) Caching/clock Performance

Today’s Agenda Fetch and Execute Registers Memory locations and addresses Addressing Modes

Execution Instruction Fetch Instruction is decoded – Register Transfer Instruction thus is executed Results are stored

CPU Registers Instruction register (IR) Program counter (PC) Memory address register (MAR) Memory data register (MDR) General-purpose register (R 0 – R n-1 )

Memory Locations Memory consists of huge number of storage cells, each stores 1 bit. Data is usually accessed in group of n-bit groups. n is called word length. second word first word Figure 2.5. Memory words. n bits last word i th word

Example of Word

Memory Addresses Memory can either be retrieved as one word or one byte (8-bit), addresses, however, for each location are needed. A k-bit address memory has 2 k memory locations 0 – 2 k -1, memory space. 24-bit memory: 2 24 = 16,777,216 = 16M (1M=2 20 ) 32-bit memory: 2 32 = 4G (1G=2 30 ) 1K(kilo)=2 10 1T(tera)=2 40 Byte locations have addresses 0, 1, 2, … For 32 bit word length, successive words addresses are 0, 4, 8,…

Word Alignment The addresses that begin at byte addresses in multiples of the number bytes in a Word are said to be aligned in memory – 32-bit word: word addresses: 0, 4, 8,…. – 64-bit word: word addresses: 0, 8,16,….

Memory Operation Load (or Read or Fetch) – Copy the content. The memory content remains unchanged. – Address – Load – Registers can be used Store (or Write) – Content of the memory is overwritten – Address and Data – Store – Registers can be used

Primitive Operations A computer must have instructions capable of performing four types of operations – Data transfers between the memory and the processor registers – Arithmetic and logic operations on data – Program sequencing and control – I/O transfers

Register Transfer Location can be identified by symbolic name (Loc, R0) Contents of a location are denoted by placing square brackets around the name of the location (R1←[LOC], R3 ←[R1]+[R2]) For Example in Assembly language – Move LOC, R1 = R1←[LOC] – Add R1, R2, R3 = R3 ←[R1]+[R2]

Using CPU Registers Registers are faster Shorter instructions – The number of registers is smaller (e.g. 64 registers need 6 bits) Potential speedup Minimize the frequency of memory access

Branching

Condition Codes Condition code flags Condition code register / status register – N (negative) – Z (zero) – V (overflow) – C (carry) Different flags are affected by different instructions

Addressing Modes Implied – “ADD M[AR]” in “One-Address” instruction Immediate – Use of a constant in “MOV R1, 6”, i.e. R1 ← 6 Register – Indicate which register holds the operand Register Indirect – Indicate the register that holds the number of the register that holds the operand MOV R1, (R2) Autoincrement / Autodecrement – Access & update in 1 instr. Direct Address – Use the given address to access a memory location

Addressing Modes Indirect Address – Indicate the memory location that holds the address of the memory location that holds the data Relative Address – EA = PC + Relative Addr Indexed – EA = Index Register + Relative Addr Base Register – EA = Base Register + Relative Addr

Addressing Modes

Summary Fetch and Execute Registers Memory locations and addresses Addressing Modes