1 ALU ports can get input from any of the two registers ALU can perform one of the eight operations Shift unit can perform one of the four possible types.

Slides:



Advertisements
Similar presentations
Computer Organization, Bus Structure
Advertisements

Pipeline Example: cycle 1 lw R10,9(R1) sub R11,R2, R3 and R12,R4, R5 or R13,R6, R7.
Microprocessor Dr. Rabie A. Ramadan Al-Azhar University Lecture 4.
Instructor: Yuzhuang Hu The Shifter 3 clock cycles will be needed if using a bidirectional shift register with parallel load.  A clock.
Chapter 6 Microlevel of H1 and V1. We start with some concepts from Chapter 5 that are essential for this chapter.
VHDL Development for ELEC7770 VLSI Project Chris Erickson Graduate Student Department of Electrical and Computer Engineering Auburn University, Auburn,
Savio Chau Single Cycle Controller Design Last Time: Discussed the Designing of a Single Cycle Datapath Control Datapath Memory Processor (CPU) Input Output.
1 TK2633TK Microprocessor Architecture DR MASRI AYOB.
CMPUT Computer Organization and Architecture II1 CMPUT229 - Fall 2003 TopicE: Building a Data Path and a Control Path for a Microprocessor José Nelson.
Lec 8: Pipelining Kavita Bala CS 3410, Fall 2008 Computer Science Cornell University.
CMPUT Computer Organization and Architecture II1 CMPUT329 - Fall 2003 TopicH: Building a Data Path and a Control Path for a Microprocessor José Nelson.
CPEN Digital System Design Chapter 9 – Computer Design
Design and Synthesis of a RISC Stored-Program Machine
Dr. Rabie A. Ramadan Al-Azhar University Lecture 6
1 Computer Organization Today: First Hour: Computer Organization –Section 11.3 of Katz’s Textbook –In-class Activity #1 Second Hour: Test Review.
Computer Architecture Lecture 9 by Engineer A. Lecturer Aymen Hasan AlAwady 10/2/2014 University of Kufa - Information Technology Research and Development.
Computer Design Basics
CPU Design. Introduction – The CPU must perform three main tasks: Communication with memory – Fetching Instructions – Fetching and storing data Interpretation.
1 Pipelining Reconsider the data path we just did Each instruction takes from 3 to 5 clock cycles However, there are parts of hardware that are idle many.
Chap 7. Register Transfers and Datapaths. 7.1 Datapaths and Operations Two types of modules of digital systems –Datapath perform data-processing operations.
1 Instruction memory is used to store a program Processor gets one instruction at a time It stores it locally (like) I0, I1 registers PC points to next.
ARM MIPS.  32 registers, each 32-bit wide. 30 are general purpose, R30(Hi) and R31(Low) are reserved for the results of long multiplication (64-bit.
Sample Code (Simple) Run the following code on a pipelined datapath: add1 2 3 ; reg 3 = reg 1 + reg 2 nand ; reg 6 = reg 4 & reg 5 lw ; reg.
A four function ALU A 00 ADD B MUX SUB 11 Result AND OR
TEAM FRONT END ECEN 4243 Digital Computer Design.
Datapath and Control Unit Design
PC Memory 2 16 by 16 bit Reg. File ALUALU SEXT 16 I[5:0] I[7:0] 8 6 Controller +1 Rd1 Rd2 Wr WE Out1 In Out2 I Memory 2 16 by 16 bit 16 WE ZEXT 16 I[11:0]
Instructor: Alexander Stoytchev CprE 281: Digital Logic.
Register Transfer Languages (RTL)
The System Bus. Conceptual CPU Block Diagram Datapath Regs Buses ALU Control Unit Bus Interface IR etc. PC etc. Control Signals Status Signals PSR System.
Elements of Datapath for the fetch and increment The first element we need: a memory unit to store the instructions of a program and supply instructions.
Datapath and Control AddressInstruction Memory Write Data Reg Addr Register File ALU Data Memory Address Write Data Read Data PC Read Data Read Data.
RegDst 1: RegFile destination No. for the WR Reg. comes from rd field. 0: RegFile destination No. for the WR Reg. comes from rt field.
1 To write any register, we need register address and a write signal A 3-bit write address is decoded if write signal is present One of the eight registers.
Instructor: Alexander Stoytchev CprE 281: Digital Logic.
Single Cycle Controller Design
1 Instructions are stored in a memory called instruction memory To execute each instruction, we get the instruction out of memory, store in a register.
Access the Instruction from Memory
STUDY OF PIC MICROCONTROLLERS.. Design Flow C CODE Hex File Assembly Code Compiler Assembler Chip Programming.
Single Cycle CPU.
More Devices: Control (Making Choices)
Decode and Operand Read
Instructor: Alexander Stoytchev
Design of the Control Unit for Single-Cycle Instruction Execution
CSCI206 - Computer Organization & Programming
Instructor: Alexander Stoytchev
Instructor: Alexander Stoytchev
Design of the Control Unit for One-cycle Instruction Execution
CSCI206 - Computer Organization & Programming
Instruction encoding We’ve already seen some important aspects of processor design. A datapath contains an ALU, registers and memory. Programmers and compilers.
The Processor Lecture 3.2: Building a Datapath with Control
Instructor: Alexander Stoytchev
April 3 Fun with MUXes Implementing arbitrary logical functions
CSC 220: Computer Organization
Enhancing Data Path M 4-bit Reg X A L U
Storing Control A L U We need a memory to store control
A register design with parallel load input
Tri-state buffer A circuit which allows an input to go to output when desired Otherwise it behaves as if “nothing” is connected to the wire An equivalent.
Instructor: Alexander Stoytchev
Processor: Multi-Cycle Datapath & Control
Control Unit (single cycle implementation)
Overview Last lecture Digital hardware systems Today
Instruction encoding We’ve already seen some important aspects of processor design. A datapath contains an ALU, registers and memory. Programmers and compilers.
Control units In the last lecture, we introduced the basic structure of a control unit, and translated our assembly instructions into a binary representation.
Control Unit for Multiple Cycle Implementation
Review: The whole processor
Control sequence to add two registers
Control Unit for Multiple Cycle Implementation
COMS 361 Computer Organization
Processor: Datapath and Control
Presentation transcript:

1 ALU ports can get input from any of the two registers ALU can perform one of the eight operations Shift unit can perform one of the four possible types of shifts Operations on data path Mem Unit Mem Addr WM EM Reg File Reg Addr WRER ALUALU 4-bit Reg 4-bit Reg MUXMUX MUXMUX LD1 M2 M1 LD2 OpCode Input enable M- Reg enable LDM ShiftShift

2 ALU operations are –000Output A100A + B –001Output B101A - B –010Output A and B –011Output A or B Shift Operation –00Shift left without M10Shift left with M –01shift right without M11Shift left with M On the main bus, we can enable output of ALU, M-register, Input, Register File, and Memory unit (only one of them at a time) The main bus data data can be written into the two registers, Register File, and Memory unit ALU output can also be written into M register ALU operations and data transfers

3 To transfer Input to any register –Enable input to main bus –Write in register by enabling LD1 or LD2 –Other control signals should be asserted in such a way so that they do not cause any change in state To transfer a register data to M register –Select register through one of the multiplexers –Select ALU operation to transfer selected port to output –Write in M register by asserting LDM signal To transfer Register file or memory unit output to a register –Select appropriate register in Register file or memory location in memory and enable appropriate unit output to bus –Write in a register using LD1 or LD2 Some actual transfers

4 We can eliminate some components in the data path For example two registers and multiplexers may not be needed The register file is two ported Modified Data Path Mem Unit Mem Addr WM EM ALUALU OpCode Input EI Reg File WA WR RA2RA1 EALU M- Reg EMR LDM SHIFTSHIFT Shift code

5 Register file contain R registers –R can be 4 or 8 or 16 or 32 Each register has n bits (n can be 4, 8, 16, or 32) n defines the data path width Register file has two R-to-1 n-bit multiplexers Each multiplexer multiplexes all register to select one to output Any register can be read out on any of the two ports –Each multiplexer needs a log R bits address (RA1 or RA2) Any register can be written using data on the bus –Write address is specified by WA (log R bits) –Write is enabled by WR signal Register File

6 An instruction specifies is a set of bit specifying an operation It includes –an operation code to specify an ALU function –RA1 and RA2 bits to specify two registers –WA to specify which register to write back –shift code to specify shift operation Includes operation like no shift, shift left or right with M register –Memory address and control to read or write memory Not every instruction specifies all instructions A nano instruction is set of control bits for all units Operations