Register Transfer Specification And Design

Slides:



Advertisements
Similar presentations
Chapter #8: Finite State Machine Design 8
Advertisements

1ASM Algorithmic State Machines (ASM) part 1. ASM2 Algorithmic State Machine (ASM) ‏ Our design methodologies do not scale well to real-world problems.
Give qualifications of instructors: DAP
Chapter 9 Computer Design Basics. 9-2 Datapaths Reminding A digital system (or a simple computer) contains datapath unit and control unit. Datapath: A.
EKT 221 : Digital 2 ASM.
Introduction to Data Flow Graphs and their Scheduling Sources: Gang Quan.
CS 151 Digital Systems Design Lecture 37 Register Transfer Level
3/20/20091 More State Machines. Multiple processes.
The Control Unit: Sequencing the Processor Control Unit: –provides control signals that activate the various microoperations in the datapath the select.
Dr. Turki F. Al-Somani VHDL synthesis and simulation – Part 3 Microcomputer Systems Design (Embedded Systems)
Digital Design – Optimizations and Tradeoffs
Give qualifications of instructors: DAP
CPEN Digital System Design Chapter 9 – Computer Design
FINITE STATE MACHINES (FSMs) Dr. Konstantinos Tatas.
George Mason University ECE 448 – FPGA and ASIC Design with VHDL Finite State Machines State Diagrams, State Tables, Algorithmic State Machine (ASM) Charts,
Introduction to Data Flow Graphs and their Scheduling Sources: Gang Quan.
Digital Computer Design Fundamental
IKI Register-transfer Design
Instructor: Yuzhuang Hu State-Machine Diagrams contd. (Chapter 5, Section 5-7) Use boolean expressions to simplify the diagram. S0S0 S1S1.
Chapter 8 -- Analysis and Synthesis of Synchronous Sequential Circuits.
Modern VLSI Design 4e: Chapter 8 Copyright  2008 Wayne Wolf Topics Basics of register-transfer design: –data paths and controllers; –ASM charts. Pipelining.
Computer Organization & Programming Chapter 5 Synchronous Components.
DLD Lecture 26 Finite State Machine Design Procedure.
EKT 221 : Chapter 4 Computer Design Basics
Algorithmic state machines
Datapath - performs data transfer and processing operations The control unit sends: – Control signals – Control outputs The control unit receives: – External.
IAY 0600 Digital Systems Design Register Transfer Level Design (GCD example) Lab. 7 Alexander Sudnitson Tallinn University of Technology.
ECE 448 Lecture 6 Finite State Machines State Diagrams vs. Algorithmic State Machine (ASM) Charts.
ECE DIGITAL LOGIC LECTURE 21: FINITE STATE MACHINE Assistant Prof. Fareena Saqib Florida Institute of Technology Fall 2015, 11/24/2015.
Chapter 8 Solving Larger Sequential Problems.
Appendix C Basics of Logic Design. Appendix C — Logic Basic — 2 Logic Design Basics §4.2 Logic Design Conventions Objective: To understand how to build.
George Mason University Finite State Machines Refresher ECE 545 Lecture 11.
Controller Implementation
Partitioning of a digital system.
Sequential Networks and Finite State Machines
Figure 8.1. The general form of a sequential circuit.
ECE 448 Lecture 6 Finite State Machines State Diagrams, State Tables, Algorithmic State Machine (ASM) Charts, and VHDL Code.
ANALYSIS OF SEQUENTIAL CIRCUITS
Computer Design Basics
Introduction Introduction to VHDL Entities Signals Data & Scalar Types
Chap 7. Register Transfers and Datapaths
IAY 0600 Digital Systems Design
SLIDES FOR CHAPTER 12 REGISTERS AND COUNTERS
ECE 448 Lecture 6 Finite State Machines State Diagrams vs. Algorithmic State Machine (ASM) Charts.
IAY 0600 Digital Systems Design
CS/COE0447 Computer Organization & Assembly Language
Reading: Hambley Chapters
Digital Principles and Design Algorithmic State Machines
Instructor: Alexander Stoytchev
Instructor: Alexander Stoytchev
Sequential Networks and Finite State Machines
Instructor: Alexander Stoytchev
Lesson 4 Synchronous Design Architectures: Data Path and High-level Synthesis (part two) Sept EE37E Adv. Digital Electronics.
Instructor: Alexander Stoytchev
Instructor: Alexander Stoytchev
Instructor: Alexander Stoytchev
Instructor: Alexander Stoytchev
REGISTER TRANSFER LEVEL (RTL) DESIGN Using ASM CHART
Overview Part 1 - Registers, Microoperations and Implementations
IAS 0600 Digital Systems Design
Figure 8.1. The general form of a sequential circuit.
KU College of Engineering Elec 204: Digital Systems Design
Computer Design Basics
Instructor: Alexander Stoytchev
ECE 448 Lecture 6 Finite State Machines State Diagrams, State Tables, Algorithmic State Machine (ASM) Charts, and VHDL Code.
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.
ECE 448 Lecture 6 Finite State Machines State Diagrams vs. Algorithmic State Machine (ASM) Charts.
CSE 370 – Winter Sequential Logic-2 - 1
Instructor: Michael Greenbaum
Presentation transcript:

Register Transfer Specification And Design Chapter 8 Register Transfer Specification And Design Chapter 4 Karnaugh Maps Don’t Care Conditions Technology Mapping Optimization, Conversions, Decomposing, Retiming

Chapter preview Boolean algebra Logic gates and flip-flops 3 3 Boolean algebra Logic gates and flip-flops 6 Finite-state machine 4 6 Logic design techniques Sequential design techniques Binary system and data representation 2 7 5 Storage components Combinational components Generalized finite-state machines 8 8 Boolean Cubes for n = 1, 2, 3, and 4 Register-transfer design 9 Processor components

Register-transfer design Each standard or custom IP components consists of one or more datapaths and control units. To synthesize such IP we introduce the model of a FSM with a data (FSMD). We demonstrate synthesis algorithms for FSMD model, including component selection, resource sharing, pipelining and scheduling. Chapter Summary

High-level block diagram Register-transfer-level block diagram Design Model High-level block diagram Register-transfer-level block diagram

Ones-counter specification Start = 0 Start = 1 Done=0; Data = Input Done=0; Ocount = 0 Done=0; Mask = 1 Done=0; Temp = Data AND Mask Data = 0 Done=0; Ocount = Ocount + Temp Done=1; Data = Data >> 1 Data = 0 Done=1; Output =Ocount

FSDM Definition In Chapter 6 we defined an FSM as a quintuple < S, I, O, f, h > where S is a set of states, I and O are the sets of input and output symbols: f : S × I S , and h : S × I O More precisely, I = A1 × A2 ×… Ak S = Q1 × Q2 ×… Qm O = Y1 × Y2 ×… Yn Where Ai, , is an input signal, Qi, is the flip-flop output and Yi, is an output signal. To define a FSMD, we define a set of variables V = V1 × V2 ×…Vq which defines the state of the datapath by defining the values of all variables in each state. where IC = A1 × A2 ×… Ak as before and ID = B1 × B2 ×… Bp, Where OC = Y1 × Y2 ×… Yn as before and OD = Z1 × Z2 ×… Zr.

FSDM Definition With formal definition of expressions and relations over a set of variables we can simplify function f : ( S ×V ) × I => S ×V by separating it into two parts: fC and fD. The function fC defines the next state of the control unit fC : S × IC × STAT => S while the function fD defines the values of datapath variables in the next state fD : S × V × ID => V fD : {fDi : V × ID => V : { Vj = ej | Vj elof V, ej elof Expr ( V × ID )}} Also, hC : S × IC × STAT => OC and hD : S × V × ID => OD

FSMD specification of Ones-counter State and output table State and output table with variable assignments State-action table

Algorithmic-State-Machine Graphic representation of FSMD model Equivalent to state-action table Similar to a flowchart used for program description

ASM Symbols

ASM rules Rule 1: The chart must define a unique next state for each state and set of conditions. Rule 2: Every path defined by the network of condition boxes must lead to another state. Undefined next state Undefined exit path

ASM chart for Ones-counter (a) State-based (Moore) chart (b) Input-based (Mealy) chart

State-action tables for Ones-counter State-based table

State-action tables for Ones-counter Input-based table

Logic schematics for Ones-counter D2 = Q2(next) = s2DataLSB + S3 + S4(Data 0)’ = Q1Q’0Data’LSB + Q1Q0 + Q2Q’0(Data 0)’ D1 = Q1(next) = s1 + s2DataLSB + s4(Data 0) = Q’2Q’1Q’0 + Q1Q’0DataLSB + Q2Q’0(Data 0) D0 = Q0(next) = s0Start + s2DataLSB + s4(Data 0)’ = Q’2Q’1Q’0Start+Q1Q’0DataLSB+Q2Q’0(Dara 0)’ S1= s4 =Q2Q’0 S0 = s2 + s4 = Q1Q’0 + Q2Q’0 E = s3 = Q1Q0 Load =s1 = Q’2Q’1Q0 Done = Output enable = s5 = Q2Q0 State-based version

Logic schematics for Ones-counter D1 = Q1 ( next ) = s1+s2 = Q’1Q0 + Q1Q’0 D0 = Q0 ( next ) = s0Start + s2( Data 0 )’ = Q’1Q’0Start + Q1Q’0 ( Data 0 ) S1 =s2( Data 0 ) = Q1Q’0( Data 0 ) S0 = s1 + s2( Data 0 ) = Q’1Q0 + Q1Q’0( Data 0 ) E = s2DataLSB = Q1Q’0DataLSB Load = s1 = Q’1Q0 Done = Output enable = s3= Q1Q0 Input-based version

Register-transfer synthesis Block diagram Register sharing Functional unit sharing Bus sharing FlowChart of Square-root approximation

Resource usage in square-root approximation Variable usage Operation usage Flowchart of Square-root approximation

Simple library components Absolute value unit (version 1) (b) Absolute value unit (version 2) (c) Min unit (d) Max unit (e) Min/Max unit (f) 1-bit right shifter (g) 3-bit right shifter (h) 1-bit/3-bit right shifter (i) Adder (j) Subtractor (k) Adder/Subtractor

Connectivity requirements a b t1 t2 x y t3 t4 t5 t6 t7 abs1 1 abs2 min max >>3 >>1 - + Flowchart of Square-root approximation Connectivity table

Register sharing (Variable merging) Grouping of variables with non-overlaping lifetimes Each group shares one register Grouping reduces number of registers needed in the design Two algorithms: left-edge and graph-partitioning

Left-edge algorithm

Register sharing by left-edge algorithm X b t1 t2 x y t3 t4 t5 t6 t7 R1 = {a, t1, x, t7} R2 = {b, t2, y, t4, t6} R3 = {t2, t5 } Sorted list of variables Register assignments Datapath schematic Flowchart

Merging variables with common sources and destination Partial Flowchart Datapath without register sharing Datapath with register sharing

Graph partitioning algorithm (a) Initial compatibility graph General partitioning algorithm

Graph partitioning algorithm for SRA (a) Initial compatibility graph (b) Compatibility graph after merging t3, t5 and t6 (c) Compatibility graph after merging t1, x and t7 (d) Compatibility graph after merging t2 and y (e) Final compatibility graph Flowchart

Register assignment generated by the graph-partitioning algorithm R1 = [ a , t1 , x , t7 ] R2 =[b , t2 , y , t3 , t5 , t6 ] R3= [ t4 ] Register assignments Datapath

Functional unit sharing (operator merging) Group non-concurrent operations Each group shares one functional unit Sharing reduces number of functional units Prioritized grouping by reducing connectivity Clustering algorithm used for grouping

Functional unit sharing Partial Flowchart Non-shared design Shared design

Complex library components Unit for computing minimum, maximum and absolute value Unit for computing addition, subtraction, minimum and maximum Unit for computing addition, subtraction, and absolute value Unit for computing addition, subtraction, minimum, maximum and absolute value

Operator merging for SRA implementation (a) Compatibility graph (b) Cost table (c) Merging alternative (d) Cost table Flowchart (e) Merging alternative (f) Cost table

Datapath connectivity (a) Datapath schematic for unit allocation from figure 8.22 (c) FlowChart (b) Datapath schematic for unit allocation from figure 8.22 (e)

Priorities in unit merging (a) Partial Flowchart (b) Design without merged units (c) Design with merged units

Unit merging for SRA datapath (b) Compatibility graph after merging of + and _ (a) Compatibility graph (c) Compatibility graph after merging of min, + and _ (d) Final graph partitions Flowchart

SRA datapath generated by prioritized partitioning R1 = [ a, t1, x, t7 ] R2 = [ b, t2, y, t3, t5, t6 ] R3 = [ t4 ] AU1 = [ |b| / min / + / - ] AU2 = [ |a| / max /] SH1 = [ >>1 ] SH2 = [ >>3 ] (a) Register and functional unit allocation (b) Datapath schematic

Bus sharing ( connection merging ) Group connections that are not used concurrently Each group forms a bus Connection merging reduces number of wires Clustering algorithm is demonstrated

Connection merging in SRA datapath Bus1 = [ A, C, D, E, H ] Bus2 = [ B, F, G ] Bus3 = [ I, K, M ] Bus4 = [ J, L, N ] (a) Datapath for SRA (e) Bus assignment (c) Compatibility graph for input buses (d) Compatibility graph for output buses (b) Connectivity usage table

Connection merging in SRA datapath Bus1 = [ A, C, D, E, H ] Bus2 = [ B, F, G ] Bus3= [ I, K, M ] Bus4 = [ J, L, N ] Datapath for SRA Bus assignment (f) Bus oriented datapath

Register merging Group register with non-overlapping accesses Each group assigned to one register file Register grouping reduces number of ports, and therefore number of buses Demonstration with clustering algorithm

Register merging R1 = [ a, t1, x, t7 ] R2 = [ b, t2, y, t3, t5, t6 ] R3 = [ t4 ] (a) Register assignment (b) Register access table (c) Compatibility graph ASM Chart (d) Datapath schematic

Chaining and multi-cycling Chaining allows serial execution of two or more operations in each state Chaining reduces number of states and increases performance Multi-cycling allows one operation to be executed over two or more clock cycles Multi-cycling reduces size of functional units Chaining and multi-cycling are used on noncritical paths to improve resource utilization and performance

SRA datapath with chained units (b) Datapath schematic (a) Flowchart

SRA datapath with multi-cycle units (b) Datapath schematic (a) Flowchart

Pipelining Pipelining improves performance at a very small additional cost Pipelining divides resources into stages and uses all stage concurrently for different data ( assembly line principle) Pipelining principles works on several levels: Unit pipelining Control pipelining Datapath pipelining

Pipelined arithmetic unit

SRA datapath with single AU (b) Datapath schematic (a) Flowchart

Datapath with pipelined functional unit (a) Datapath with pipelined AU (b) Timing diagram

(b) Pipelined datapath (c) Register and functional unit assignment Datapath pipelining (b) Pipelined datapath R1 = [ a, t1 ] R3 = [ t3, t5, t6, t7 ] R2 = [ b, t2 ] R4 = [ x ] AU1 = [ abs/min/max ] R5 = [ t4 ] AU2 = [ +/-/max ] (a) Flowchart (c) Register and functional unit assignment

(b) Pipelined datapath Datapath pipelining (b) Pipelined datapath (d) Timing diagram

Timing diagram for datapath pipeline with pipelined units

Pipelined FSMD implementation (a) Standard FSMD implementation (b) FSMD implementation with control and datapath pipelining

Flowcharts for pipelined FSMDs (b) FSMD implementation with control and datapath pipelining (b) Flowchart for control pipeline with status register (c) Flowchart for control pipeline with status register and control registers (a) Flowchart (d) Flowchart for control and datapath pipeline

Scheduling RT description such as ASM chart specifies data operations in each state Flowcharts or programming languages do not have states, but only specify order in which operations are executed. Scheduling transforms flowcharts or programs with RT descriptions Two types of scheduling (a) resource constrained (resource given, minimize time) (b) time constrained (time given, minimize resources)

Control/dataflow graph for SRA (a) Flowchart (b) Control/Data flow graph

Basic schedules (a) ASAP schedule (a) ALAP schedule

List scheduling algorithm

Resource-constrained scheduling (a) ASAP (b) ALAP (c) Ready list with nobilities (d) RC schedule

Time-constrained scheduling

TC schedule for SRA algorithm (a) ASAP (b) ALAP (c) TC schedule

Probability distribution graph before, during and after TC scheduling (a) Initial probability distribution graph (b) Distribution graph after max, + and – were scheduled (c) Distribution graph after max, + and –,>>3 and >>1 were scheduled (c) Distribution graph for final scheduled

Chapter summary FSMD model RT specification with We introduced RT design: FSMD model RT specification with Procedure for synthesis from RT specification Design Optimization through Design Pipelining Scheduling of flowcharts Static-action tables ASM charts Register sharing Unit chaining Functional unit sharing Multi-clocking Bus sharing Unit pipelining Control pipelining Datapath pipelining

Example 7.1 Map Representation