Team DataPath Research Computer Architechture. PC and IF in the Processor.

Slides:



Advertisements
Similar presentations
CS/COE1541: Introduction to Computer Architecture Datapath and Control Review Sangyeun Cho Computer Science Department University of Pittsburgh.
Advertisements

331 W08.1Spring :332:331 Computer Architecture and Assembly Language Spring 2006 Week 8: Datapath Design [Adapted from Dave Patterson’s UCB CS152.
1 Today  All HW1 turned in on time, this is great!  HW2 will be out soon —You will work on procedure calls/stack/etc.  Lab1 will be out soon (possibly.
The Processor: Datapath & Control
1  1998 Morgan Kaufmann Publishers Chapter Five The Processor: Datapath and Control.
Chapter 5 The Processor: Datapath and Control Basic MIPS Architecture Homework 2 due October 28 th. Project Designs due October 28 th. Project Reports.
Levels in Processor Design
CMPUT Computer Organization and Architecture II1 CMPUT229 - Fall 2003 TopicE: Building a Data Path and a Control Path for a Microprocessor José Nelson.
ENEE350 Ankur Srivastava University of Maryland, College Park Based on Slides from Mary Jane Irwin ( )
Computer Structure - Datapath and Control Goal: Design a Datapath  We will design the datapath of a processor that includes a subset of the MIPS instruction.
The Processor 2 Andreas Klappenecker CPSC321 Computer Architecture.
CMPUT Computer Organization and Architecture II1 CMPUT329 - Fall 2003 TopicH: Building a Data Path and a Control Path for a Microprocessor José Nelson.
Chapter Five The Processor: Datapath and Control.
Copyright 1998 Morgan Kaufmann Publishers, Inc. All rights reserved. Digital Architectures1 Machine instructions execution steps (1) FETCH = Read the instruction.
Datapath and Control Andreas Klappenecker CPSC321 Computer Architecture.
Processor I CPSC 321 Andreas Klappenecker. Midterm 1 Thursday, October 7, during the regular class time Covers all material up to that point History MIPS.
King Fahd University of Petroleum and Minerals King Fahd University of Petroleum and Minerals Computer Engineering Department Computer Engineering Department.
The Processor Andreas Klappenecker CPSC321 Computer Architecture.
Chapter 4 Sections 4.1 – 4.4 Appendix D.1 and D.2 Dr. Iyad F. Jafar Basic MIPS Architecture: Single-Cycle Datapath and Control.
COSC 3430 L08 Basic MIPS Architecture.1 COSC 3430 Computer Architecture Lecture 08 Processors Single cycle Datapath PH 3: Sections
Processor: Datapath and Control
Gary MarsdenSlide 1University of Cape Town Chapter 5 - The Processor  Machine Performance factors –Instruction Count, Clock cycle time, Clock cycles per.
CS2100 Computer Organisation The Processor: Datapath (AY2015/6) Semester 1.
Computer Architecture and Design – ECEN 350 Part 6 [Some slides adapted from A. Sprintson, M. Irwin, D. Paterson and others]
TEAM FRONT END ECEN 4243 Digital Computer Design.
1 A single-cycle MIPS processor  An instruction set architecture is an interface that defines the hardware operations which are available to software.
D ATA P ATH OF A PROCESSOR (MIPS) Module 1.1 : Elements of computer system UNIT 1.
December 26, 2015©2003 Craig Zilles (derived from slides by Howard Huang) 1 A single-cycle MIPS processor  As previously discussed, an instruction set.
Computer Architecture Lecture 9 MIPS ALU and Data Paths Ralph Grishman Oct NYU.
ECE-C355 Computer Structures Winter 2008 The MIPS Datapath Slides have been adapted from Prof. Mary Jane Irwin ( )
Chapter 4 From: Dr. Iyad F. Jafar Basic MIPS Architecture: Single-Cycle Datapath and Control.
February 22, 2016©2003 Craig Zilles (derived from slides by Howard Huang) 1 A single-cycle MIPS processor  As previously discussed, an instruction set.
1 CS/COE0447 Computer Organization & Assembly Language Chapter 5 Part 2.
Datapath and Control AddressInstruction Memory Write Data Reg Addr Register File ALU Data Memory Address Write Data Read Data PC Read Data Read Data.
COM181 Computer Hardware Lecture 6: The MIPs CPU.
Gary MarsdenSlide 1University of Cape Town Computer Architecture – Introduction Andrew Hutchinson & Gary Marsden (me) ( ) September 2003.
MIPS Processor.
Computer Architecture Lecture 6.  Our implementation of the MIPS is simplified memory-reference instructions: lw, sw arithmetic-logical instructions:
Access the Instruction from Memory
CS161 – Design and Architecture of Computer Systems
Single-Cycle Datapath and Control
Computer Architecture
ECS 154B Computer Architecture II Spring 2009
MIPS Processor.
Processor (I).
CS/COE0447 Computer Organization & Assembly Language
MIPS processor continued
COSC 2021: Computer Organization Instructor: Dr. Amir Asif
CSCI206 - Computer Organization & Programming
CS/COE0447 Computer Organization & Assembly Language
CSCI206 - Computer Organization & Programming
Single-Cycle CPU DataPath.
CSCI206 - Computer Organization & Programming
MIPS Processor.
Levels in Processor Design
The Processor Lecture 3.2: Building a Datapath with Control
COSC 2021: Computer Organization Instructor: Dr. Amir Asif
COSC 2021: Computer Organization Instructor: Dr. Amir Asif
Lecture 14: Single Cycle MIPS Processor
Processor: Multi-Cycle Datapath & Control
MIPS processor continued
CS/COE0447 Computer Organization & Assembly Language
Control Unit for Multiple Cycle Implementation
FloorPlan for Multicycle MIPS
The Processor: Datapath & Control.
COMS 361 Computer Organization
MIPS Processor.
Processor: Datapath and Control
CS/COE0447 Computer Organization & Assembly Language
Presentation transcript:

Team DataPath Research Computer Architechture

PC and IF in the Processor

Program Counter & Instruction Fetch PC o Instruction address register o Increments after fetch to read next instruction o Jumps, branches, subroutines, & returns Instruction Fetch o Copies the address in the PC into the IR o Retrieves the instruction content from memory

PC & IF Inputs and Outputs Inputs o Instruction Memory o Incrementor o Control Line Outputs o Databus to Instruction Decode

Instruction Types R-Type (Register Only) I-Type (Immediate Value) J-Type (Jump)

The Register File! What is it? Contains all 32 registers; some available to the programmer Registers are designated using 5 of the bits in the instruction Each register contains 32 bits of information What does it do? Controls the flow of information to or from registers Reads two registers at a time and writes to one Receives a control bit for knowing when to write Reads from registers on the positive edge of the clock cycle and writes to a register on the negative edge

The Register File! Lets learn how to read! From Computer Organization & Design: The Hardware/Software Interface 1.The 5 bits determining the registers are used to control a Mux that picks from 32 registers. (5 bits = 32 distinct bit sequences) 2.Data is passed along to the ALU. 3.This all happens when either the "Write" (from Figure B.8.8) is on or off and during the rising edge of the clock cycle.

The Register File! How about writing? 1. Register number is determined in the decoder which, when ANDed with "Write", sets that register to have it's data overwritten. 2.The data being written is coming from the ALU on a 32 bit bus connected to each register. 3.Performs the write to the register when the clock cycle has a negative slope. From Computer Organization & Design: The Hardware/Software Interface

The Register File! Going a little deeper... Implementation: Registers Each bit of a register can be made up of D-Flip Flop The D signifies the data that is being inputted. Q is the output, where the bit is read from Writing Uses 32:1 Mux for toggling the appropriate register ANDs this signal with the RegWrite control signal to enable writing to register A 32 bit bus is attached to each register Reading A 32x32 to 32 Mux must be used. This type of Mux chooses between 32 registers with 32 bits each and outputs the 32 bits of the chosen register designated in 5 bits in the instruction One method of implementing this is to use 32, 32 to 1 Multiplexers D-Flip Flop From physicsforums.com

The ALU and You! Fig 4.2 Computer Organize and Design

Fun Facts What is an alu? o Main brain Mclain of the PLP Architecture o Combination of Adders and Logic Gates What does it do? o Performs Mathmatical and Logical Operations Why do we need it? o Allows us to process Data in a multitude of ways

3 ALUs within PLP Architecture. o PC incrementation o Branching Instructions o R and I-type Arithmetic and Logical Instructions

ALU R-type Instruction Example From PLP wiki

Simple Data Path Fig Computer Organize and Design I-type R-type Branching

Oh It makes sense Function determined by Control ALU gives us POWAH o Can do process data in a multitude of ways

Mux, Sign Extension, Logical Shift, and Branching and Jumping Mux (Multiplexer) o It is used anytime you need to make a decision between multiple inputs Sign Extension o It is used to keep a number value the same but have the number take up more bits Logical Shift o It is used to move the information in a word to right or left Branching and Jumping o They are used to move from one line of code to another

Inputs and Outputs Mux, Sign Extend and Logical Shift Mux o 3 inputs and 1 output Sign Extend o In this example there are 16 inputs and 32 outputs Logical Shift o In this example there are 8 inputs and outputs o The number of outputs will always equal the number or inputs

Where They Fit In Mux, Sign Extension, and Logical Shift Mux, Sign Extend and Logical Shift o These are all used many times in the mips architecture and they can be used or placed anywhere one of these operations is needed

Branching and Jumping Branching (Orange) and Jumping (Blue) o They take many inputs form many different parts of the architecture and it outputs back to the program counter

The Memory

The Memory: Structure Blue lines : control signals (MemWrite, MemRead) Black lines : 32-bit values (Address, Write data, Read data) It is a 2 32 x32 memory

If the data memory is to be read => o MemRead=1 ( the active signal ) o MemWrite=0 If the data memory is to be written => o MemRead=0 o MemWrite=1 ( the active signal )  Address?  Write data?  Read data?

The instructions R-type instruction, add, sub, and, or, slt... o MemWrite and MemRead are set to 0, o Memory doesn’t have to do anything. Branch instructions, o MemWrite and MemRead are set to 0, o Memory doesn’t have to do anything. Lw instruction, o MemWrite is set to 0 and MemRead to 1. o Need to compute the effective address =>sign extend. o ALUOp should be ADD (010). o ALUSrc fixed to 1. Complete address in its line => value wanted at Read data Sw instruction, o MemRead is set to 0 and MemWrite to 1. o Need to compute the effective address => sign extend. o ALUOp should be ADD (010). o ALUSrc fixed to 1. We put the data in the Write data => value saved at the specified address

Two New Instructions Variable Logical Shift Left (sllv) o Purpose: shift left by a number of bits that is unknown to the programmer. The shift is stored in a register instead of in an immediate value. Variable Logical Shift Right (srlv) o Purpose: shift right by a number of bits that is unknown to the programmer. The shift is stored in a register instead of in an immediate value.

Two New Instructions Cont. Current implementation example: li $t0 5 loop: slli $t1, $t2, 0x1 subi $t0, $t0, 1 // value shift counter bne $t0,$Zero,loop Example with new instructions sllv $t1, $t2, $t0 This saves 3n-2 instructions.

Wrap-Up Research will enable code implementation of a PLP- architecture processor. The hardware will comprise all five stages of the processor. Behavioral Verilog code will "construct" the processor within an FPGA. Questions?