Dale Roberts Department of Computer and Information Science, School of Science, IUPUI CSCI N305 Information Representation: Machine Instructions.

Slides:



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

Computer Architecture and the Fetch-Execute Cycle
Central Processing Unit
PART 5: (2/2) Processor Internals CHAPTER 15: CONTROL UNIT OPERATION 1.
Microprocessor and Microcontroller Based Systems Instructor: Eng.Moayed N. EL Mobaied The Islamic University of Gaza Faculty of Engineering Electrical.
Room: E-3-31 Phone: Dr Masri Ayob TK 2123 COMPUTER ORGANISATION & ARCHITECTURE Lecture 5: CPU and Memory.
CHAPTER 4 COMPUTER SYSTEM – Von Neumann Model
Memory - Registers Instruction Sets
Processor Types And Instruction Sets Barak Perelman CS147 Prof. Lee.
Computer Organization and Architecture
Lecture 13 - Introduction to the Central Processing Unit (CPU)
Department of Computer and Information Science, School of Science, IUPUI Dale Roberts, Lecturer Computer Science, IUPUI CSCI.
Processor Structure & Operations of an Accumulator Machine
Micro-operations Are the functional, or atomic, operations of a processor. A single micro-operation generally involves a transfer between registers, transfer.
Information Representation: Machine Instructions
Introduction to Computing Systems from bits & gates to C & beyond The Von Neumann Model Basic components Instruction processing.
The CPU Central Processing Unit. 2 Reminder - how it fits together processor (CPU) memory I/O devices bus.
Chapter 4 MARIE: An Introduction to a Simple Computer.
Computer Architecture Lecture 09 Fasih ur Rehman.
CPU How It Works. 2 Generic Block Diagram CPU MemoryInputOutput Address Bus Data Bus.
Model Computer CPU Arithmetic Logic Unit Control Unit Memory Unit
Lecture 14 Today’s topics MARIE Architecture Registers Buses
Computer Organization & Assembly Language © by DR. M. Amer.
Computer Architecture Memory, Math and Logic. Basic Building Blocks Seen: – Memory – Logic & Math.
Fetch-execute cycle.
Computer Hardware A computer is made of internal components Central Processor Unit Internal External and external components.
Computer Studies/ICT SS2
CSE 241 Computer Organization Lecture # 8 Ch. 7 Control Unit Dr. Tamer Samy Gaafar Dept. of Computer & Systems Engineering.
Dale & Lewis Chapter 5 Computing components
Digital Computer Concept and Practice Copyright ©2012 by Jaejin Lee Control Unit.
Register Transfer Languages (RTL)
Basic Elements of Processor ALU Registers Internal data pahs External data paths Control Unit.
Question What technology differentiates the different stages a computer had gone through from generation 1 to present?
GROUP 2 CHAPTER 16 CONTROL UNIT Group Members ๏ Evelio L. Hernandez ๏ Ashwin Soerdien ๏ Andrew Keiper ๏ Hermes Andino.
Dale Roberts Department of Computer and Information Science, School of Science, IUPUI CSCI 230 Dale Roberts, Lecturer Information.
Control Unit Operations Chapter10:. What is Control Unit (CU)?(1)  Part of a CPU or other device that directs its operation.  Tells the rest of the.
Chapter 10 Control Unit Operation “Controls the operation of the processor”
Processor Organization and Architecture Module III.
Designing a CPU –Reading a programs instruction from memory –Decoding the instruction –Executing the instruction –Transferring Data to/From memory / IO.
Chapter 2 Data Manipulation © 2007 Pearson Addison-Wesley. All rights reserved.
Chapter 20 Computer Operations Computer Studies Today Chapter 20.
BASIC COMPUTER ARCHITECTURE HOW COMPUTER SYSTEMS WORK.
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 Chapter 1 Basic Structures Of Computers. Computer : Introduction A computer is an electronic machine,devised for performing calculations and controlling.
Types of Micro-operation  Transfer data between registers  Transfer data from register to external  Transfer data from external to register  Perform.
Functions of Processor Operation Addressing modes Registers i/o module interface Memory module interface Interrupts.
The Stored Program Computer
Lecture 13 - Introduction to the Central Processing Unit (CPU)
Micro-Operations A computer executes a program Fetch/execute cycle
William Stallings Computer Organization and Architecture
William Stallings Computer Organization and Architecture 7th Edition
Chapter 15 Control Unit Operation
Computer Architecture
The Processor and Machine Language
Functional Units.
CS149D Elements of Computer Science
The Von Neumann Model Basic components Instruction processing
MARIE: An Introduction to a Simple Computer
William Stallings Computer Organization and Architecture 7th Edition
The Little Man Computer
Chapter 14 Control Unit Operation
William Stallings Computer Organization and Architecture 8th Edition
GCSE OCR 1 The CPU Computer Science J276 Unit 1
Information Representation: Machine Instructions
Objectives Describe common CPU components and their function: ALU Arithmetic Logic Unit), CU (Control Unit), Cache Explain the function of the CPU as.
Computer Architecture
COMPUTER ARCHITECTURE
Presentation transcript:

Dale Roberts Department of Computer and Information Science, School of Science, IUPUI CSCI N305 Information Representation: Machine Instructions

Dale Roberts Review: Computer Organization A Typical Von-Neumann Architecture Example: Input unit Output unit Memory unit Arithmetic and logic unit (ALU) Central processing unit (CPU) Secondary storage unit Control Circuit (ex: PC: Program Counter) ALU MemoryI/O CPU

Dale Roberts Memory Computer memory is comparable to a collection of numbered mailboxes. To identify individual cells in a machine’s main memory, each cell is assigned a unique name, called its address The organization of byte-size memory cell Hello, ASCII... Data Address Address Bus Data Bus Low-order endHigh-order end Least Significant Bit (LSB)Most Significant Bit (MSB)

Dale Roberts Registers – Program Counter Program Counter (PC) Contains the memory address of the next instruction to be executed. The contents of the program counter are copied to the memory address register before an instruction is fetched from memory. At the completion of the fetched instruction, the control unit updates the program counter to point to the next instruction which is to be fetched. memory address registercontrol unitmemory address registercontrol unit

Dale Roberts Registers – Memory Address Register Memory Address Register (MAR) A register located on the central processing unit which is in turn connected to the address lines of the system. This register specifies the address in memory where information can be found and can be also used to point to a memory location where information is to be stored. central processing unit central processing unit

Dale Roberts Registers – Memory Buffer Register Memory Buffer Register (MBR) A register located on the central processing unit which is in turn connected to the data lines of the system. The main purpose of this register is to act as an interface between the central processing unit and memory. When the appropriate signal is received by the control unit, the memory location stored in the memory address register is used to copy data from or to the memory buffer register. central processing unit central processing unit control unitmemory address registercentral processing unit central processing unit control unitmemory address register

Dale Roberts Registers – Instruction Register Instruction Register (IR) A register located on the central processing unit which holds the contents of the last instruction fetched. This instruction is now ready to be executed and is accessed by the control unit. central processing unitcontrol unit central processing unitcontrol unit

Dale Roberts IR Structure The Instruction Register typically has a structure that includes operation code and an optional operand. Everyone calles the operation code an “Opcode” It is up to the manufacturer to determine how many bits comprise an instruction, and which bits store the opcode and operand.

Dale Roberts Registers - Accumulator Accumulator (ACC) A register located on the central processing unit. The contents can be used by the arithmetic- logic unit for arithmetic and logic operations, and by the memory buffer register. Usually, all results generated by the arithmetic-logic unit end up in the accumulator. central processing unitarithmetic- logic unitmemory buffer registerarithmetic-logic unitcentral processing unitarithmetic- logic unitmemory buffer registerarithmetic-logic unit

Dale Roberts Arithmetic Logic Unit Arithmetic-Logic Unit (ALU) Performs arithmetic operations such as addition and subtraction as well as logical operations such as AND, OR and NOT. Most operations require two operands. One of these operands usually comes from memory via the memory buffer register, while the other is the previously loaded value stored in the accumulator. The results of an arithmetic-logic unit operation is usually transfered to the accumulator. memory buffer registeraccumulator memory buffer registeraccumulator

Dale Roberts Memory Memory is made up of a series of zero's (0) and one's (1) called bits or binary. These individual bits are grouped together in lots of eight and are referred to as a byte. Every byte in memory can be accessed by a unique address which identifies its location. The memory in modern computers contains millions of bytes and is often referred to as random-access memory (RAM). Memory interacts with the MAR and MBR to read and write values from memory via a bus.

Dale Roberts Fetch/Execute Cycle All computers have an instruction execution cycle. A basic instruction execution cycle can be broken down into the following steps: Fetch cycle Fetch cycle Execute cycle Execute cycle

Dale Roberts Fetch cycle The illustrated fetch cycle above can be summarized by the following points: PC => MAR MAR => memory => MBR MBR => IR PC incremented

Dale Roberts Execute Cycle After the CPU has finished fetching an instruction, the CU checks the contents of the IR and determines which type of execution is to be carried out next. This process is known as the decoding phase. The instruction is now ready for the execution cycle.

Dale Roberts Types of Opcodes The actions within the execution cycle can be categorized into the following four groups: CPU - Memory: Data may be transferred from memory to the CPU or from the CPU to memory. CPU - I/O: Data may be transferred from an I/O module to the CPU or from the CPU to an I/O module. Data Processing: The CPU may perform some arithmetic or logic operation on data via the arithmetic-logic unit (ALU). arithmetic-logic unitarithmetic-logic unit Control: An instruction may specify that the sequence of operation may be altered. For example, the program counter (PC) may be updated with a new memory address to reflect that the next instruction fetched, should be read from this new location. program counterprogram counter

Dale Roberts LOAD ACC, memory The illustrated LOAD operation summarized in the following points: IR [address portion] => MAR MAR => memory => MBR MBR => ACC

Dale Roberts ADD ACC, memory The illustrated ADD operation can be summarized in the following points: IR [address portion] => MAR MAR => memory => MBR MBR + ACC => ALU ALU => ACC

Dale Roberts Acknowledgements Several graphics and terms were obtained from Jonathan Michael Auld Central Queensland University.Central Queensland University xComputer and its machine instructions were developed by David Eck.