RT-Level Custom Design. This Week in DIG II  Introduction  Combinational logic  Sequential logic  Custom single-purpose processor design  Review.

Slides:



Advertisements
Similar presentations
Chapter 7 Henry Hexmoor Registers and RTL
Advertisements

Topics covered: CPU Architecture CSE 243: Introduction to Computer Architecture and Hardware/Software Interface.
Give qualifications of instructors: DAP
Introduction to Data Flow Graphs and their Scheduling Sources: Gang Quan.
ECE 551 Digital System Design & Synthesis Lecture 09 Synthesis of Common Verilog Constructs.
CS 151 Digital Systems Design Lecture 37 Register Transfer Level
Embedded Systems Design: A Unified Hardware/Software Introduction 1 Chapter 2: Custom single-purpose processors.
ECE 331 – Digital System Design
Embedded Systems Design: A Unified Hardware/Software Introduction 1 Chapter 2: Custom single-purpose processors.
Processor Technology and Architecture
Chapter 5: Computer Systems Organization Invitation to Computer Science, Java Version, Third Edition.
Embedded Systems Design: A Unified Hardware/Software Introduction 1 Chapter 2: Custom single-purpose processors.
Dr. Turki F. Al-Somani VHDL synthesis and simulation – Part 3 Microcomputer Systems Design (Embedded Systems)
From Combinational to Sequential Circuits to Simple Processors
Give qualifications of instructors: DAP
Basic Input/Output Operations
Chapter 2: Custom single-purpose processors
Chapter 4 Processor Technology and Architecture. Chapter goals Describe CPU instruction and execution cycles Explain how primitive CPU instructions are.
1 Introduction Chapters 2 & 3: Introduced increasingly complex digital building blocks –Gates, multiplexors, decoders, basic registers, and controllers.
ENEE 408C Lab Capstone Project: Digital System Design Fall 2005 Sequential Circuit Design.
CPEN Digital System Design Chapter 9 – Computer Design
George Mason University ECE 448 – FPGA and ASIC Design with VHDL Finite State Machines State Diagrams, State Tables, Algorithmic State Machine (ASM) Charts,
03/08/2005 © J.-H. Jiang1 Retiming and Resynthesis EECS 290A – Spring 2005 UC Berkeley.
Introduction to Data Flow Graphs and their Scheduling Sources: Gang Quan.
From Combinational to Sequential Circuits to Simple Processors
Sequential Circuits Chapter 4 S. Dandamudi To be used with S. Dandamudi, “Fundamentals of Computer Organization and Design,” Springer,  S.
1 COMP541 State Machines Montek Singh Feb 8, 2012.
Unit 14 Derivation of State Graphs
Chapter 5: Computer Systems Organization Invitation to Computer Science, Java Version, Third Edition.
Hussein Bin Sama && Tareq Alawneh
1 2-Hardware Design Basics of Embedded Processors (cont.)
George Mason University ECE 545 – Introduction to VHDL ECE 545 Lecture 5 Finite State Machines.
Modern VLSI Design 4e: Chapter 8 Copyright  2008 Wayne Wolf Topics Basics of register-transfer design: –data paths and controllers; –ASM charts. Pipelining.
1 Code optimization “Code optimization refers to the techniques used by the compiler to improve the execution efficiency of the generated object code”
Introduction to State Machine
DLD Lecture 26 Finite State Machine Design Procedure.
Lecture 21: Registers and Counters (1)
1 Copyright  2001 Pao-Ann Hsiung SW HW Module Outline l Introduction l Unified HW/SW Representations l HW/SW Partitioning Techniques l Integrated HW/SW.
Modern VLSI Design 3e: Chapter 8 Copyright  1998, 2002 Prentice Hall PTR Topics n Basics of register-transfer design: –data paths and controllers; –ASM.
1 COMP541 Finite State Machines - 1 Montek Singh Sep 22, 2014.
Digital Logic Design Basics Combinational Circuits Sequential Circuits Pu-Jen Cheng Adapted from the slides prepared by S. Dandamudi for the book, Fundamentals.
ECE 448 Lecture 6 Finite State Machines State Diagrams vs. Algorithmic State Machine (ASM) Charts.
Dr. Turki F. Al-Somani VHDL synthesis and simulation.
1 2-Hardware Design Basics of Embedded Processors (cont.)
CS 61C: Great Ideas in Computer Architecture Finite State Machines, Functional Units 1 Instructors: Vladimir Stojanovic and Nicholas Weaver
CS 110 Computer Architecture Lecture 9: Finite State Machines, Functional Units Instructor: Sören Schwertfeger School of.
C OMBINATIONAL L OGIC D ESIGN 1 Eng.Maha AlGubali.
1 COMP541 Sequential Logic – 2: Finite State Machines Montek Singh Feb 29, 2016.
Resource Sharing in LegUp. Resource Sharing in High Level Synthesis Resource Sharing is a well-known technique in HLS to reduce circuit area by sharing.
1 Introduction to Engineering Spring 2007 Lecture 19: Digital Tools 3.
George Mason University Finite State Machines Refresher ECE 545 Lecture 11.
CS2100 Computer Organisation
Register Transfer Specification And Design
2-Hardware Design Basics of Embedded Processors (cont.)
Introduction Introduction to VHDL Entities Signals Data & Scalar Types
Chap 7. Register Transfers and Datapaths
Chapter 2: Custom single-purpose processors
ECE 448 Lecture 6 Finite State Machines State Diagrams vs. Algorithmic State Machine (ASM) Charts.
Basics Combinational Circuits Sequential Circuits Ahmad Jawdat
Lecture 17 Logistics Last lecture Today HW5 due on Wednesday
Computer Architecture
Guest Lecture by David Johnston
Chapter 2: Custom single-purpose processors
Chapter 2: Custom single-purpose processors
Lecture 17 Logistics Last lecture Today HW5 due on Wednesday
ECE 448 Lecture 6 Finite State Machines State Diagrams, State Tables, Algorithmic State Machine (ASM) Charts, and VHDL code ECE 448 – FPGA and ASIC Design.
Chapter 2: Custom single-purpose processors
ECE 448 Lecture 6 Finite State Machines State Diagrams vs. Algorithmic State Machine (ASM) Charts.
EMBEDDED SYSTEMS Prof. Ch.Ramesh Embedded Systems 1.
ECE 352 Digital System Fundamentals
Presentation transcript:

RT-Level Custom Design

This Week in DIG II  Introduction  Combinational logic  Sequential logic  Custom single-purpose processor design  Review  RT-level custom single-purpose processor design Chapter 2: Custom single- purpose processors Tomorrow in the lab….  Continue working on this week’s assignment  Add computational functionality  Surreal moments with Dr. P.

RT-level custom single-purpose processor design  We often start with a state machine  Rather than algorithm  Cycle timing often too central to functionality  Programming languages don’t support cycle-by-cycle timing  FSMDs make cycle-by-cycle timing explicit  Example  Bus bridge that converts 4-bit bus to 8-bit bus  Start with FSMD  Known as register-transfer (RT) level  Exercise: complete the design Problem Specification WaitFirst4RecFirst4Start data(3..0)=data_in WaitSecond4 rdy_in=1 rdy_in=0 RecFirst4End rdy_in=1 RecSecond4Start data(7..4)=data_in RecSecond4End rdy_in=1 rdy_in=0 rdy_in=1 rdy_in=0 Send8Start data_out=data rdy_out=1 Send8End rdy_out=0 FSMD Bridge A single-purpose processor that converts two 4-bit inputs, arriving one at a time over data_in along with a rdy_in pulse, into one 8-bit output on data_out along with a rdy_out pulse. Sender 4 data_in(4) rdy_in data_out(8) rdy_out 8 Receiver clock rdy_in=0

RT-level custom single-purpose processor design (cont’) WaitFirst4RecFirst4Start data_lo_ld=1 WaitSecond4 rdy_in=1 rdy_in=0 RecFirst4End rdy_in=1 RecSecond4Start data_hi_ld=1 RecSecond4End rdy_in=1 rdy_in=0 rdy_in=1 rdy_in=0 Send8Start data_out_ld=1 rdy_out=1 Send8End rdy_out=0 (a) Controller rdy_inrdy_out data_lodata_hi data_in(4) (b) Datapath data_out data_out_lddata_hi_ld data_lo_ld clk to all registers data_out Bridge Create the data path using the 4- step process as before, and convert FSMD to FSM (controller)

A Few Points to Remember  We have seen two custom single purpose processor design procedure, one that starts with a software program, the other directly at the FSMD level.  Which one to use when?  Use the former program based method, whenever the problem requires for algorithm implementation, heavy math, etc.  Use the latter method, whenever the problem is mostly a control application (like our bridge example).  Starting at FSMD level is also known as Register-Transfer (RT) level design, since an FSMD describes which registers have their data transferred to which other registers at each state.

Optimizing single-purpose processors  In GCD example, we ignored several simplification opportunities :  The FSM had several states did not do anything  Datapath had two adders, where in fact, one may be sufficient  Etc.  In a typical real custom design task, we typically wish to optimize every possible parameter / procedure.  Optimization is the task of making design metric values the best possible  Optimization opportunities  original program  FSMD  datapath  FSM

Optimizing the original program  Analyze program attributes and look for areas of possible improvement  number of computations  size of variable  time and space complexity  operations used multiplication and division very expensive

Optimizing the original program (cont’) 0: int x, y; 1: while (1) { 2: while (!go_i); 3: x = x_i; 4: y = y_i; 5: while (x != y) { 6: if (x < y) 7: y = y - x; else 8: x = x - y; } 9: d_o = x; } 0: int x, y, r; 1: while (1) { 2: while (!go_i); // x must be the larger number 3: if (x_i >= y_i) { 4: x=x_i; 5: y=y_i; } 6: else { 7: x=y_i; 8: y=x_i; } 9: while (y != 0) { ??????? } 13: d_o = x; } original program optimized program GCD(42, 8) - 9 iterations to complete the loop x and y values evaluated as follows : (42, 8), (43, 8), (26,8), (18,8), (10, 8), (2,8), (2,6), (2,4), (2,2).

Optimizing the FSMD  Areas of possible improvements  merge states states with constants on transitions can be eliminated, transition taken is already known states with independent operations can be merged  separate states states which require complex operations (a*b*c*d) can be broken into smaller states to reduce hardware size t 1 =b*c, t 2 =d*e, a=t 1 *t 2 requires only one MUX (as opposed to three)  Scheduling: the task of assigning operations from the original problem to states in an FSMD  Beware: Note that the optimized process will take fewer clock cycles. This may not be acceptable for certain application that are highly clock dependent!

Optimizing the FSMD (cont.) int x, y; 2: go_i !go_i x = x_i y = y_i x<yx>y y = y -xx = x - y 3: 5: 7: 8: d_o = x 9: y = y -x 7: x = x - y 8: 6-J: x!=y 5: !(x!=y) x<y!(x<y) 6: 5-J: 1: 1 !1 x = x_i y = y_i 4: 2: 2-J: !go_i !(!go_i) d_o = x 1-J: 9: int x, y; 3: original FSMD optimized FSMD Beware: Avoid the common mistake of assuming that a variable assigned in a state can have the newly assigned value on an outgoing arc of that state

Optimizing the datapath  Sharing of functional units  one-to-one mapping, as done previously (two separate subtractors), may not necessary  if same operation occurs in different states, they can share a single functional unit (use single subtractor, with a MUX whose control bit chooses the inputs as (x and y) or (y and x).  Multi-functional units  ALUs support a variety of operations, it can be shared among operations occurring in different states

Optimizing the FSM  State encoding  task of assigning a unique bit pattern to each state in an FSM  size of state register and combinational logic vary  can be treated as an ordering problem  State minimization  task of merging equivalent states into a single state state equivalent if for all possible input combinations the two states generate the same outputs and transitions to the next same state Note that the state merging done in the previous example is NOT state minimization, because we changed the timing of the circuit. By the time we arrive at FSM, the timing of the output is assumed to be unchangeable !

Summary  Custom single-purpose processors  Straightforward design techniques  Can be built to execute algorithms  Typically start with FSMD  CAD tools can be of great assistance