RTL Hardware Design by P. Chu Chapter 91. 1. Poor design practice and remedy 2. More counters 3. Register as fast temporary storage 4. Pipelined circuit.

Slides:



Advertisements
Similar presentations
COUNTERS Counters with Inputs Kinds of Counters Asynchronous vs
Advertisements

CSE 205: Digital Logic Design
Registers and Counters
Copyright 2001, Agrawal & BushnellVLSI Test: Lecture 261 Lecture 26 Logic BIST Architectures n Motivation n Built-in Logic Block Observer (BILBO) n Test.
Programmable Interval Timer
The 8085 Microprocessor Architecture
Finite State Machine Chapter 10 RTL Hardware Design by P. Chu.
Digital Digital: Chapter 8. Sequential Logic Design Practices 1 Chapter 8. Sequential Logic Design Practices.
RTL Hardware Design by P. Chu Chapter 161 Clock and Synchronization.
Contemporary Logic Design Sequential Case Studies © R.H. Katz Transparency No Chapter #7: Sequential Logic Case Studies 7.1, 7.2 Counters.
Embedded Systems Hardware:
11/16/2004EE 42 fall 2004 lecture 331 Lecture #33: Some example circuits Last lecture: –Edge triggers –Registers This lecture: –Example circuits –shift.
11/10/2004EE 42 fall 2004 lecture 301 Lecture #30 Finite State Machines Last lecture: –CMOS fabrication –Clocked and latched circuits This lecture: –Finite.
Logic and Computer Design Fundamentals Registers and Counters
Sequential PLD timing Registers Counters Shift registers
Embedded Systems Hardware: Storage Elements; Finite State Machines; Sequential Logic.
ELEN 468 Advanced Logic Design
Chapter #6: Sequential Logic Design 6.2 Timing Methodologies
ENGIN112 L26: Shift Registers November 3, 2003 ENGIN 112 Intro to Electrical and Computer Engineering Lecture 26 Shift Registers.
Chapter 6 Memory and Programmable Logic Devices
Lecture 21 Overview Counters Sequential logic design.
Registers and Counters
Chapter 1_4 Part II Counters
Chapter 7 Counters and Registers
EE345: Introduction to Microcontrollers Register and Counters Prof. Ahmad Abu-El-Haija.
RTL Hardware Design by P. Chu Chapter Derivation of efficient HDL description 2. Operator sharing 3. Functionality sharing 4. Layout-related circuits.
1 Registers and Counters A register consists of a group of flip-flops and gates that affect their transition. An n-bit register consists of n-bit flip-flops.
ECE Advanced Digital Systems Design Lecture 12 – Timing Analysis Capt Michael Tanner Room 2F46A HQ U.S. Air Force Academy I n t e g r i.
Digital Logic Design Review Dr. Ahmad Almulhem ahmadsm AT kfupm Phone: Office: Ahmad Almulhem, KFUPM 2010.
Counter Application (Part B) By : Pn Siti Nor Diana Ismail CHAPTER 3.
Introduction to Chapter 7
SEQUENTIAL CIRCUITS Component Design and Use. Register with Parallel Load  Register: Group of Flip-Flops  Ex: D Flip-Flops  Holds a Word of Data 
RTL Hardware Design by P. Chu Chapter Overview on sequential circuits 2. Synchronous circuits 3. Danger of synthesizing asynchronous circuit 4.
EE365 Adv. Digital Circuit Design Clarkson University Lecture #12 Registers and Counters.
Digital Design Lectures 11 & 12 Shift Registers and Counters.
Chap 7. Register Transfers and Datapaths. 7.1 Datapaths and Operations Two types of modules of digital systems –Datapath perform data-processing operations.
7-6 단일 레지스터에서 Microoperation Multiplexer-Based Transfer  Register 가 서로 다른 시간에 둘 이상의 source 에서 data 를 받을 경우 If (K1=1) then (R0 ←R1) else if (K2=1) then.
ENG241 Digital Design Week #8 Registers and Counters.
Registers and Counters Chapter 6. Digital Circuits 2 Clocked sequential circuits a group of flip-flops and combinational gates connected to form a feedback.
Chap 5. Registers and Counters. Chap Definition of Register and Counter l a clocked sequential circuit o consist of a group of flip-flops & combinational.
Chapter 1_4 Part III more on … Counters Chapter 1_4 Part III more on … Counters.
Abdullah Said Alkalbani University of Buraimi
Sequential logic circuits
Counters and Registers Synchronous Counters. 7-7 Synchronous Down and Up/Down Counters  In the previous lecture, we’ve learned how synchronous counters.
Introduction to Microprocessors - chapter3 1 Chapter 3 The 8085 Microprocessor Architecture.
EE121 John Wakerly Lecture #9
Counters.
Unit 1 – Counters and Registers Mr. Grimming. Introduction FFs and logic gates are combined to form various counters and registers. Unit Goals Goals:
Different Microprocessors Tamanna Haque Nipa Lecturer Dept. of Computer Science Stamford University Bangladesh.
ECE 448 Lecture 6 Finite State Machines State Diagrams vs. Algorithmic State Machine (ASM) Charts.
Chap 5. Registers and Counters
Instructor: Alexander Stoytchev CprE 281: Digital Logic.
REGISTER TRANSFER LANGUAGE (RTL) INTRODUCTION TO REGISTER Registers1.
RTL Hardware Design by P. Chu Chapter 9 – ECE420 (CSUN) Mirzaei 1 Sequential Circuit Design: Practice Shahnam Mirzaei, PhD Spring 2016 California State.
1 Modeling Synchronous Logic Circuits Debdeep Mukhopadhyay Associate Professor Dept of Computer Science and Engineering NYU Shanghai and IIT Kharagpur.
The 8085 Microprocessor Architecture
REGISTER TRANSFER LANGUAGE (RTL)
Chapter #6: Sequential Logic Design
Registers and Counters
The 8085 Microprocessor Architecture
EKT 221 – Counters.
EKT 221 : Digital 2 COUNTERS.
Instructor: Alexander Stoytchev
Instructor: Alexander Stoytchev
CS Fall 2005 – Lec. #5 – Sequential Logic - 1
触发器 Flip-Flops 刘鹏 浙江大学信息与电子工程学院 March 27, 2018
ECEN 248: INTRODUCTION TO DIGITAL SYSTEMS DESIGN
CSE 370 – Winter Sequential Logic - 1
CSE 370 – Winter Sequential Logic-2 - 1
The 8085 Microprocessor Architecture
Presentation transcript:

RTL Hardware Design by P. Chu Chapter 91

1. Poor design practice and remedy 2. More counters 3. Register as fast temporary storage 4. Pipelined circuit RTL Hardware Design by P. Chu Chapter 92

 Synchronous design is the most important methodology  Poor practice in the past (to save chips) ◦ Misuse of asynchronous reset ◦ Misuse of gated clock ◦ Misuse of derived clock RTL Hardware Design by P. Chu Chapter 93

RTL Hardware Design by P. Chu Chapter 94 Misuse of asynchronous reset  Poor design: use reset to clear register in normal operation.  e.g., a poorly mod-10 counter ◦ Clear register immediately after the counter reaches 1010

RTL Hardware Design by P. Chu Chapter 95

RTL Hardware Design by P. Chu Chapter 96

 Problem ◦ Glitches in transition 1001 (9) => 0000 (0) ◦ Glitches in aync_clr can reset the counter ◦ How about timing analysis? (maximal clock rate)  Asynchronous reset should only be used for power-on initialization RTL Hardware Design by P. Chu Chapter 97

RTL Hardware Design by P. Chu Chapter 98  Remedy: load “0000” synchronously

RTL Hardware Design by P. Chu Chapter 99

RTL Hardware Design by P. Chu Chapter 910 Misuse of gated clock  Poor design: use a and gate to disable the clock to stop the register to get new value  E.g., a counter with an enable signal

RTL Hardware Design by P. Chu Chapter 911

RTL Hardware Design by P. Chu Chapter 912

 Problem ◦ Gated clock width can be narrow ◦ Gated clock may pass glitches of en ◦ Difficult to design the clock distribution network RTL Hardware Design by P. Chu Chapter 913

RTL Hardware Design by P. Chu Chapter 914  Remedy: use a synchronous enable

RTL Hardware Design by P. Chu Chapter 915 Misuse of derived clock  Subsystems may run at different clock rate  Poor design: use a derived slow clock for slow subsystem

 Problem ◦ Multiple clock distribution network ◦ How about timing analysis? (maximal clock rate) RTL Hardware Design by P. Chu Chapter 916

RTL Hardware Design by P. Chu Chapter 917  Better use a synchronous one-clock enable pulse

RTL Hardware Design by P. Chu Chapter 918  E.g., second and minutes counter ◦ Input: 1 MHz clock ◦ Poor design:

RTL Hardware Design by P. Chu Chapter 919 ◦ Better design

RTL Hardware Design by P. Chu Chapter 920  VHDL code of poor design

RTL Hardware Design by P. Chu Chapter 921

RTL Hardware Design by P. Chu Chapter 922

RTL Hardware Design by P. Chu Chapter 923

RTL Hardware Design by P. Chu Chapter 924  Remedy: use a synchronous 1-clock pulse

RTL Hardware Design by P. Chu Chapter 925

 Power is a major design criteria now  In CMOS technology ◦ Dynamic power is proportional to the switching frequency of transistors ◦ High clock rate implies high switching freq  Clock manipulation ◦ Can reduce switching frequency ◦ But should not be done at RT level RTL Hardware Design by P. Chu Chapter 926

 Development flow: 1. Design/synthesize/verify a regular synchronous subsystems 2(a). Derived clock: use special circuit (PLL etc.) to obtain derived clocks 2(b). Gated clock: use “power optimization” software tool to convert some register into gated clock RTL Hardware Design by P. Chu Chapter 927

RTL Hardware Design by P. Chu Chapter More counters  Counter circulates a set of specific patterns  Counter: ◦ Binary ◦ Gray counter ◦ Ring counter ◦ Linear Feedback Shift Register (LFSR) ◦ BCD counter

RTL Hardware Design by P. Chu Chapter 929  Binary counter: ◦ State follows binary counting sequence ◦ Use an incrementor for the next-state logic

RTL Hardware Design by P. Chu Chapter 930  Gray counter: ◦ State changes one-bit at a time ◦ Use a Gray incrementor

RTL Hardware Design by P. Chu Chapter 931

RTL Hardware Design by P. Chu Chapter 932

 Circulate a single 1  E.g., 4-bit ring counter: 1000, 0100, 0010, 0001  n patterns for n-bit register  Output appears as an n-phase signal  Non self-correcting design ◦ Insert “0001” at initialization and circulate the pattern in normal operation ◦ Fastest counter RTL Hardware Design by P. Chu Chapter 933

RTL Hardware Design by P. Chu Chapter 934

RTL Hardware Design by P. Chu Chapter 935

RTL Hardware Design by P. Chu Chapter 936  Self-correcting design: shifting in a ‘1’ only when 3 MSBs are 000

 A sifter reg with a special feedback circuit to generate the serial input  The feedback circuit performs xor operation over specific bits  Can circulate through 2 n -1 states for an n-bit register RTL Hardware Design by P. Chu Chapter 937

RTL Hardware Design by P. Chu Chapter 938  E.g, 4-bit LFSR

RTL Hardware Design by P. Chu Chapter 939  Property of LFSR ◦ N-bit LFSR can cycle through 2 n -1 states ◦ The feedback circuit always exists ◦ The sequence is pseudorandom

RTL Hardware Design by P. Chu Chapter 940  Application of LFSR ◦ Pseudorandom: used in testing, data encryption/decryption ◦ A counter with simple next-state logic e.g., 128-bit LFSR using 3 xor gates to circulate patterns (takes years for a 100 GHz system)

RTL Hardware Design by P. Chu Chapter 941

RTL Hardware Design by P. Chu Chapter 942

RTL Hardware Design by P. Chu Chapter 943  Read remaining of Section (design to including state)  Read Section (BCD counter, design similar to the second/minute counter in Section 9.1.3

 Duty cycle: percentage of time that the signal is asserted  PWM: use a signal, w, to specify the duty cycle ◦ Duty cycle is w/16 if w is not “0000” ◦ Duty cycle is 16/16 if w is “0000”  Implemented by a binary counter with a special output circuit RTL Hardware Design by P. Chu Chapter 944

RTL Hardware Design by P. Chu Chapter 945

RTL Hardware Design by P. Chu Chapter 946

RTL Hardware Design by P. Chu Chapter 947

 RAM ◦ RAM cell designed at transistor level ◦ Cell use minimal area ◦ Behave like a latch ◦ For mass storage ◦ Need a special interface logic  Register ◦ D FF requires much larger area ◦ Synchronous ◦ For small, fast storage ◦ E.g., register file, fast FIFO, Fast CAM (content addressable memory) RTL Hardware Design by P. Chu Chapter 948

 Registers arranged as an 1-d array  Each register is identified with an address  Normally has 1 write port (with write enable signal)  Can has multiple read ports RTL Hardware Design by P. Chu Chapter 949

RTL Hardware Design by P. Chu Chapter 950  E.g., 4-word register file w/ 1 write port and two read ports

 Register array: ◦ 4 registers ◦ Each register has an enable signal  Write decoding circuit: ◦ 0000 if wr_en is 0 ◦ 1 bit asserted according to w_addr if wr_en is 1  Read circuit: ◦ A mux for each read por RTL Hardware Design by P. Chu Chapter 951

RTL Hardware Design by P. Chu Chapter 952  2-d data type needed

RTL Hardware Design by P. Chu Chapter 953

RTL Hardware Design by P. Chu Chapter 954

RTL Hardware Design by P. Chu Chapter 955

RTL Hardware Design by P. Chu Chapter 956 FIFO Buffer  “Elastic” storage between two subsystems

 Circular queue implementation  Use two pointers and a “generic storage” ◦ Write pointer: point to the empty slot before the head of the queue ◦ Read pointer: point to the tail of the queue RTL Hardware Design by P. Chu Chapter 957

RTL Hardware Design by P. Chu Chapter 958

 FIFO controller ◦ Read and write pointers: 2 counters ◦ Status circuit:  Difficult  Design 1: Augmented binary counter  Design 2: with status FFs ◦ LSFR as counter RTL Hardware Design by P. Chu Chapter 959

RTL Hardware Design by P. Chu Chapter 960

RTL Hardware Design by P. Chu Chapter 961  Augmented binary counter: ◦ increase the counter by 1 bits ◦ Use LSBs for as register address ◦ Use MSB to distinguish full or empty

RTL Hardware Design by P. Chu Chapter 962

RTL Hardware Design by P. Chu Chapter 963

RTL Hardware Design by P. Chu Chapter 964

RTL Hardware Design by P. Chu Chapter 965  2 extra status FFs ◦ Full_erg/empty_reg memorize the current staus ◦ Initialized as 0 and 1 ◦ Modified according to wr and rd signals:  00: no change  11: advance read pointer/write pointer; full/empty no change  10: advance write pointer; de-assert empty; assert full if needed (when write pointer=read pointer)  01: advance read pointer; de-assert full; asserted empty if needed (when write pointer=read pointer)

RTL Hardware Design by P. Chu Chapter 966

RTL Hardware Design by P. Chu Chapter 967

RTL Hardware Design by P. Chu Chapter 968

RTL Hardware Design by P. Chu Chapter 969  Non-binary counter for the pointer ◦ Exact location does not matter as long as the write pointer and read pointer follow the same pattern ◦ Other counters can be used for the second scheme ◦ E.g, use LFSR

RTL Hardware Design by P. Chu Chapter Pipelined circuit  Two performance criteria: ◦ Delay: required time to complete one task ◦ Throughput: number of tasks completed per unit time.  E.g., ATM machine ◦ Original: 3 minutes to process a transaction delay: 3 min; throughput: 20 trans per hour ◦ Option 1: faster machine 1.5 min to process delay: 1.5 min; throughput: 40 trans per hour ◦ Option 2: two machines delay: 3 min; throughput: 40 trans per hour  Pipelined circuit: increase throughput

RTL Hardware Design by P. Chu Chapter 971  Pipeline: overlap certain operation  E.g., pipelined laundry:

 Non-pipelined: ◦ Delay: 60 min ◦ Throughput 1/60 load per min  Pipelined: ◦ Delay: 60 min ◦ Throughput k/(40+k*20) load per min about 1/20 when k is large ◦ Throughput 3 times better than non-pipelined RTL Hardware Design by P. Chu Chapter 972

RTL Hardware Design by P. Chu Chapter 973 Pipelined combinational circuit

RTL Hardware Design by P. Chu Chapter 974

RTL Hardware Design by P. Chu Chapter 975 Adding pipeline to a comb circuit  Candidate circuit for pipeline: ◦ enough input data to feed the pipelined circuit ◦ throughput is a main performance criterion ◦ comb circuit can be divided into stages with similar propagation delays ◦ propagation delay of a stage is much larger than the setup time and the clock-to-q delay of the register.

RTL Hardware Design by P. Chu Chapter 976  Procedure ◦ Derive the block diagram of the original combinational circuit and arrange the circuit as a cascading chain ◦ Identify the major components and estimate the relative propagation delays of these components ◦ Divide the chain into stages of similar propagation delays ◦ Identify the signals that cross the boundary of the chain ◦ Insert registers for these signals in the boundary.

RTL Hardware Design by P. Chu Chapter 977 Pipelined comb multiplier

RTL Hardware Design by P. Chu Chapter 978

RTL Hardware Design by P. Chu Chapter 979

RTL Hardware Design by P. Chu Chapter 980

RTL Hardware Design by P. Chu Chapter 981

RTL Hardware Design by P. Chu Chapter 982