Calculator 3: Transformation to an ALU! Design specs.

Slides:



Advertisements
Similar presentations
Data Dependencies Describes the normal situation that the data that instructions use depend upon the data created by other instructions, or data is stored.
Advertisements

ARITHMETIC LOGIC SHIFT UNIT
331 W08.1Spring :332:331 Computer Architecture and Assembly Language Spring 2006 Week 8: Datapath Design [Adapted from Dave Patterson’s UCB CS152.
Calculator Lab Exercises Bruce Wile, IBM Design Automation Conference Sunday, June 9, 2002.
Calculator Design n Calculator has 4 functions: è Add è Subtract è Shift left è Shift right n Calculator can handle 4 requests in parallel è All 4 requestors.
1  1998 Morgan Kaufmann Publishers Chapter Five The Processor: Datapath and Control.
Chapter Five The Processor: Datapath and Control.
Group 5 Alain J. Percial Paula A. Ortiz Francis X. Ruiz.
SUPERSCALAR EXECUTION. two-way superscalar The DLW-2 has two ALUs, so it’s able to execute two arithmetic instructions in parallel (hence the term two-way.
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.
Dr. Rabie A. Ramadan Al-Azhar University Lecture 6
Presented by: Sergio Ospina Qing Gao. Contents ♦ 12.1 Processor Organization ♦ 12.2 Register Organization ♦ 12.3 Instruction Cycle ♦ 12.4 Instruction.
COSC 3430 L08 Basic MIPS Architecture.1 COSC 3430 Computer Architecture Lecture 08 Processors Single cycle Datapath PH 3: Sections
Lecture 14 Today’s topics MARIE Architecture Registers Buses
Gary MarsdenSlide 1University of Cape Town Chapter 5 - The Processor  Machine Performance factors –Instruction Count, Clock cycle time, Clock cycles per.
Lecture 2 Microprocessor Architecture Image from:
D75P 34 – HNC Computer Architecture
A four function ALU A 00 ADD B MUX SUB 11 Result AND OR
Processor Architecture
Dale & Lewis Chapter 5 Computing components
Digital Computer Concept and Practice Copyright ©2012 by Jaejin Lee Control Unit.
Calculator Lab Exercises Bruce Wile, IBM Design Automation Conference Sunday, June 9, 2002.
Fundamentals of Programming Languages-II
CPU Overview Computer Organization II 1 February 2009 © McQuain & Ribbens Introduction CPU performance factors – Instruction count n Determined.
Simple ALU How to perform this C language integer operation in the computer C=A+B; ? The arithmetic/logic unit (ALU) of a processor performs integer arithmetic.
Chapter 10 Control Unit Operation “Controls the operation of the processor”
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.
CMSC 104, Lecture 061 Stored Programs A look at how programs are executed.
MICROPROCESSOR DETAILS 1 Updated April 2011 ©Paul R. Godin prgodin gmail.com.
LECTURE 4 Logic Design. LOGIC DESIGN We already know that the language of the machine is binary – that is, sequences of 1’s and 0’s. But why is this?
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.
Calculator Overview Functional Verification. Calculator Design n Calculator has 4 functions: Add Subtract Shift left Shift right n Calculator can handle.
Copyright © 2005 – Curt Hill MicroProgramming Programming at a different level.
Chapter 20 Computer Operations Computer Studies Today Chapter 20.
OPERATORS IN C CHAPTER 3. Expressions can be built up from literals, variables and operators. The operators define how the variables and literals in the.
Functions of Processor Operation Addressing modes Registers i/o module interface Memory module interface Interrupts.
Combinational Circuits
CS161 – Design and Architecture of Computer Systems
Single-Cycle Datapath and Control
Basic Processor Structure/design
Control Unit Lecture 6.
IT 251 Computer Organization and Architecture
William Stallings Computer Organization and Architecture 8th Edition
Introduction CPU performance factors
A Level Computing Component 2
\course\cpeg323-08F\Topic6b-323
Design of the Control Unit for Single-Cycle Instruction Execution
Recent from Dr. Dan Lo regarding 12/11/17 Dept Exam
A451: Computer Systems and Programming
Design of the Control Unit for One-cycle Instruction Execution
MIPS ALU.
MARIE: An Introduction to a Simple Computer
\course\cpeg323-05F\Topic6b-323
Topic 5: Processor Architecture Implementation Methodology
Programming in JavaScript
The Processor Lecture 3.2: Building a Datapath with Control
Fundamental Concepts Processor fetches one instruction at a time and perform the operation specified. Instructions are fetched from successive memory locations.
COSC 2021: Computer Organization Instructor: Dr. Amir Asif
COSC 2021: Computer Organization Instructor: Dr. Amir Asif
Programming in JavaScript
ECE 352 Digital System Fundamentals
Recent from Dr. Dan Lo regarding 12/11/17 Dept Exam
The Processor: Datapath & Control.
MIPS ALU.
MIPS ALU.
Presentation transcript:

Calculator 3: Transformation to an ALU! Design specs

Overview of calc1 Calc3 is is the third in a series. The following describes the first calc. The first design is a simple 4 port calculator, where each port can send in 1 command at a time. The commands consist of add, subtract, shift left, and shift right. The operand data accompanies the commands. Since there are 4 ports, there could be up to four oustanding commands at once. The input/output timing on a single port is as follows: req1_data_in req1_cmd_in out_data1 out_resp1 The lightening bolt represents "some number of cycles passing". The data accompanies a successful response signal. A second request from the same port is prohibited until the response from the first command is received. Internally, there are two ALUs, one that processes all add commands, and the second for all shift commands. Proirity logic dispatches the individual commands to the ALUs.

Overview of calc2 Calc3 is is the third in a series. The following describes the second calc. The second design is much like the first, except that each port may now have up to 4 outstanding commands at a time. Each command from a port is sent in serially (one at a time), but the calc logic may respond "out-of-order", depending upon the internal state of the queues. As a result, each command is now accompanied by a 2 bit tag, which will identify the command when the response is received. A possible timing diagram is: The lightening bolt represents "some number of cycles passing". The data accompanies a successful response signal. Descrition continued on next page....

Overview of calc2 (continued) A timing diagram of back-to-back commands might look like this: The lightening bolt represents "some number of cycles passing". The data accompanies a successful response signal. Responses may or may not be in order, but the tags will identify which command the response is for. There may be up to 16 commands outstanding at once (4 ports, 4 commands each). As in the first calc design, the commands consist of add, subtract, shift left, and shift right.

Calc3 Overview n Design now has 16 internal data registers n Arithmetic operands no longer sent by requestor n Operand data is read internally from registers n Two new commands added to access registers n Fetch from register x; Store to register x n Two new branch commands n Successful branch causes next command from port to be skipped n Each requester can still send in up to 4 commands n 2 bit tag on request n Using same tag simulaneously is not supported

Calc3 Overview (continued) n Each port requestor is sending an instruction stream n In the first two calc designs, the data accompanied the command. But in this design, the arithmetic ops reference operand registers internal to the design. Therefore, instruction ordering ("instruction stream") concepts must be obeyed by the design so that within each port, the commands may only proceed out-of-order when the operand registers do not conflict. n The ordering rules follow in this document.

I/O protocols For each requestor X: Inputs: reqX_cmd(0:3) ä add: 0001 adds contents of d1 to d2 and stores in r1 ä subtract: 0010 subtracts contents of d2 from d1 and stores in r1 ä shift left: 0101 shifts contents of d1 to the left d2(27:31) places and stores in r1 ä shift right:0110 shifts contents of d1 to the right d2(27:31) places and stores in r1 ä store: 1001 stores reqX_data(0:31) into r1 ä fetch:1010 fetches contents of d1 and outputs it on out_dataX(0:31) ä branch if zero: 1100 skip next valid command if contents of d1 are 0 ä branch if equal: 1101 skip next valid command if contents of d1 and d2 are equal reqX_d1(0:3) reqX_d2(0:3) reqX_r1(0:3) reqX_tag(0:1) reqX_data(0:31) Outputs: outX_resp(0:1) ä Successful completion: 01 ä overflow/underflow error:10 ä Command skipped due to branch: 11 outX_tag(0:1) outX_data(0:31)

I/O timing reqX_cmd(0:3) reqX_d1(0:3) reqX_d2(0:3) reqX_r1(0:3) reqX_tag(0:1) outX_resp(0:1) outX_tag(0:1) Basic timing of a single arithmetic command:

I/O timing reqX_cmd(0:3) reqX_d1(0:3) reqX_d2(0:3) reqX_r1(0:3) reqX_tag(0:1) reqX_data(0:31) outX_resp(0:1) outX_tag(0:1) Basic timing of a store command:

I/O timing reqX_cmd(0:3) reqX_d1(0:3) reqX_d2(0:3) reqX_r1(0:3) reqX_tag(0:1) outX_resp(0:1) outX_tag(0:1) outX_data(0:31) Basic timing of a fetch command:

I/O timing reqX_cmd(0:3) reqX_d1(0:3) reqX_d2(0:3) reqX_r1(0:3) reqX_tag(0:1) outX_resp(0:1) outX_tag(0:1) outX_data(0:31) Basic timing of a branch command: valid d2 value when command is 1101 value is 1 if next command will be skipped (branch occurs)

I/O timing reqX_cmd(0:3) reqX_d1(0:3) reqX_d2(0:3) reqX_r1(0:3) reqX_tag(0:1) out_respX(0:1) out_tagX(0:1) Fastest multiple command (any cmd type) timing: (example is if only one requestor is sending commands) '00'b '11'b'10'b'01'b '00'b '10'b'01'b.... Requestor must leave dead cycle between commands. Requestor may only have 4 commands outstanding at a time, each with a unique tag. '00'b

Command that follows a branch n Any valid command can follow a branch n If the branch evaluates true, the following command will be "skipped": è Add/Sub/SL/SR will not write to array è Store will not write to array è Fetch will not return data è Branch will evaluate to false (case of branch followed by branch) n Response code of '11'b for follower indicating above action has occurred n Invalid OP codes are ignored and are NOT considered to be "command that follows a branch."

Command and ordering rules Within each requestor's (port's) instruction stream, operations can complete out of order with the following restrictions: l Operands (d1,d2) cannot be used if prior instruction in stream writes (result r1) to the operand and prior instruction has not completed. l Results (r1) cannot be written if either of the prior command's operands (d1,d2) use the same register as R1. l Same R1(result) values from different instructions must complete in order. There are no restrictions of this type across different requestors.

CALC3 Exercise Verification Class 7/24/01 - 7/27/01

Some thoughts n As in real-life, verification requires teamwork and communication n Make a testplan è Aim to get something "up and running" early, and build upon it....but plan for growth. n Split the work è Drivers, Monitors, Checkers, Coverage, reference model è How will you predict the outcome? When? n Use instructor as "designer" n Final presentations on Friday

Teams n David Smith, Peter Szewczyk, Karina Hernandez n Gernot (Gary) Gunther, Vasantha Vuyyuru n Shaun Uldrikis, Lynn Marie Kiefer n Gary Moore, Michael Halas n Corey Westrick, Fadi Zaraket n Vic Fernandes, Visda Vokhshoori n Suma Aluka, Bing Hu, Steve Goldman n Sheryll Veneracion, Ka-shan Choy