Skip to content

Devipriya1921/AdvancedSynthesisandSTAwithDC

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 

Repository files navigation

Advanced Synthesis and STA with DC

Table of Contents

Introduction

Design Compiler is an Advanced Synthesis Tool used by leading semiconductor companies across world. Design Compiler RTL synthesis solution enables users to meet today's design challenges with concurrent optimization of timing, area, power and test. Design Compiler includes innovative topographical technology that enables a predictable flow resulting in faster time to results.

Synthesis in VLSI is the process of converting your code (program) into a circuit. In terms of logic gates, synthesis is the process of translating an abstract design into a properly implemented chip. Synthesis of logic circuits plays a crucial role in optimizing the logic and achieving the targeted performance, area and power goals of an IC.

This workshop includes the following concepts:

  • Design fundamentals.
  • Setting up DC for synthesis.
  • Understanding and Analyzing the STA reports.
  • Understanding and writing the Synopsys Design Constraints [SDC].
  • Analyzing the quality of netlist synthesized.

The Tools used are:

  • Icarus Verilog : For Verilog Compilation, Simulation.
  • GTKWave : For viewing the Simulation output.
  • Synopsys Design Compiler : For Logic Synthesis
  • SAED_PDK 28_32nm Technology Node

Refer : Link for more details

Introduction to Logic Synthesis

1.1. Introduction to DC

  • Design Compiler RTL synthesis solution enables users to meet today's design challenges with concurrent optimization of timing, area, power and test. Design Compiler includes innovative topographical technology that enables a predictable flow resulting in faster time to results. Topographical technology provides timing and area prediction within 10% of the results seen post-layout enabling designers to reduce costly iterations between synthesis and physical implementation. Design Compiler also includes a scalable infrastructure that delivers 2X faster runtime on quad-core platforms.

  • Design Compiler is the core of Synopsys' comprehensive RTL synthesis solution, including Power Compiler, DesignWare, PrimeTime and DFTMAX. Design Compiler NXT is also available and includes includes best-in-class quality-of-results, congestion prediction and alleviation capabilities, physical viewer, and floorplan exploration. Additionally Design Compiler NXT produces physical guidance to IC Compiler, place-and-route solution for tighter correlation to layout and faster placement runtime.

  • The industry's most comprehensive synthesis solution:

dc synthesis-1

  • Benefits:
  1. Concurrent optimization of timing, area, power and test.
  2. Results correlate within 10% of physical implementation.
  3. Removes timing bottlenecks by creating fast critical paths.
  4. Gate-to-gate optimization for smaller area on new or legacy designs while maintaining timing Quality of Results (QoR).
  5. Cross-probing between RTL, schematic, and timing reports for fast debug.
  6. Offers more flexibility for users to control optimization on specific areas of designs.
  7. Enables higher efficiency with integrated static timing analysis, test synthesis and power synthesis.
  8. Support for multi voltage and multi supply.
  9. 2X faster runtime on quad-core compute servers.

1.2. Invoking Basic DC Setup

ENVIRONMENT SETUP

//Git Clone sky130RTLDesignAndSynthesisWorkshop. 
$ git clone https://github.com/kunalg123/sky130RTLDesignAndSynthesisWorkshop.git

sky130RTLDesignAndSynthesisWorkshop Directory has: My_Lib - which contains all the necessary library files; where lib has the standard cell libraries to be used in synthesis and verilog_model with all standard cell verilog models for the standard cells present in the lib. Ther verilog_files folder contains all the experiments for lab sessions including both verilog code and test bench codes.

Steps Include:

read_verilog <file_name>
link
compile_ultra (or) compile
report_power
report_timing
report_area

read_verilog command:

lab-1-commands after read_verilog

Invoking DC Synthesis:

lab-1-invoking dc synthesis-read_verilog cmd

gedit:

lab-2-sh gedit lab1_net v   - cmd

set_target and set_library commands:

lab-4 set target lib and link lib along with echo cmd

1.3. Introduction to ddc gui with Design vision

Design Vision Invoking:

lab-9-design vision invoking

read_ddc command:

lab-11-design vision - read_ddc lab1 ddc - cmd

Schematic View:

lab-12- schematic view - lab1_flop_with_en - read_ddc schematic view

.lib file is a collection of logical modules which includes all basic logic gates. It may also contain different flavors of the same gate (2 input AND, 3 input AND – slow, medium and fast version).

Faster cells and Slower Cells

A cell delay in the digital logic circuit depends on the load of the circuit which here is Capacitance.

Faster the charging / discharging of the capacitance --> Lesser is the Cell Delay

Inorder to charge/discharge the capacitance faster, we use wider transistors that can source more current. This will help us reduce the cell delay but at the same time, wider transistors consumer more power and area. Similarly, using narrower transistors help in reduced area and power but the circuit will have a higher cell delay. Hence, we have to compromise on area and power if we are to design a circuit with low cell delay.

Constraints

A Constraint is a guidance file given to a synthesizer inorder to enable an optimum implementation of the logic circuit by selecting the appropriate flavour of cells (fast or slow).

1.4. Labs using DC Synopsys DC Setup

Link commands:*

lab-14- setting link_library to $target_library - commands

Setting the path to default:

lab-15- setting target library default -  synopsys_dc setup

1.5 TCL Scripting

lab-16-tcl scripting commands-1

Basics of STA

2.1. Introduction to STA

Static timing analysis (STA) is a method of validating the timing performance of a design by checking all possible paths for timing violations. STA breaks a design down into timing paths, calculates the signal propagation delay along each path, and checks for violations of timing constraints inside the design and at the input/output interface.

1  Introduction to STA

2.2. Timing dot Libs

lab-1-saed32hvt_tt0p85v25c lib - timing dot libs-1

lab-1-saed32hvt_tt0p85v25c lib - timing dot libs-2

2.3. Exploring dotLib

lab-2-saed32hvt_tt0p85v25c lib - exploring dot libs-1 - hold_falling

lab-2-saed32hvt_tt0p85v25c lib - exploring dot libs-1- hold_rising

lab-3-saed32hvt_tt0p85v25c lib - exploring dot libs-1- area and other constraints

lab-3-saed32hvt_tt0p85v25c lib - exploring dot libs-1- cell

lab-3-saed32hvt_tt0p85v25c lib - exploring dot libs-1- receiver capacitance and pin(clk)

Advanced Constraints

Clock A digital clock is a repeating digital waveform used to step a digital circuit through a sequence of states. A clock signal oscillates between a high and a low state and is used like a metronome to coordinate actions of digital circuits. A clock signal is produced by a clock generator. Digital circuits rely on clock signals to know when and how to execute the functions that are programmed. If the clock in a design is like the heart of an animal, then clock signals are the heartbeats that keep the system in motion. In serial communication of digital data, clock recovery is the process of extracting timing information from a serial data stream to allow the receiving circuit to decode the transmitted symbols. This is one method of performing a process commonly known as clock and data recovery.

advanced constraints - intro - 1

3.1. Clock Tree Modelling - Uncertainty

Clock uncertainty is the difference between the arrivals of clocks at registers in one clock domain or between domains. it can be classified as static and dynamic clock uncertainties. Pre-layout and Post-layout Uncertainty. Pre CTS uncertainty is clock skew, clock Jitter and margin. After CTS skew is calculated from the actual propagated value of the clock.

Static clock uncertainty: it does not vary or varies very slowly with time. Process variation induced clock uncertainty. An example of this is clock skew.

Timing Uncertainty of clock period is set by the command set_clock_uncertainty at the synthesis stage to reserve some part of the clock period for uncertain factors (like skew, jitter, OCV, CROSS TALK, MARGIN or any other pessimism) which will occur in PNR stage. The uncertainty can be used to model various factors that can reduce the clock period. It can define for both setup and hold.

Skew: This phenomenon in synchronous circuits. The Difference in arrival of clock at two consecutive pins of a sequential element.

max insertion delay: delay of the clock signal takes to propagate to the farthest leaf cell in the design.

min insertion delay: delay of the clock signal takes to propagate to the nearest leaf cell in the design.

Latency: The delay difference from the clock generation point to the clock endpoints.

Source latency: Source latency is also called insertion delay. The delay from the clock source to the clock definition points. Source latency could represent either on-chip or off-chip latency.

Network latency: The delay from the clock definition points (create_clock) to the flip-flop clock pins.

Jitter: Jitter is the short term variations of a signal with respect to its ideal position in time. It is the variation of the clock period from edge to edge.it can vary +/- jitter value. From cycle to cycle the period and duty cycle can change slightly due to the clock generation circuitry. This can be modeled by adding uncertainty regions around the rising and falling edge of the clock waveform.

Sources of jitter:

Internal circuitry of the PLL. Thermal noise in crystal oscillators. Transmitters and receivers of resonating devices.

advanced constraints - intro - 2

3.2 Loading design get_cells, get_ports, get_nets

get_nets

lab-6-get_nets   all_connected N1 commands

get_cells

lab-4-get_cells commands

get_ports

lab-3- get_ports commands

3.3 Loading Design get_pins, get_clocks, querying_clocks

get_pins

lab-7-get_pins commands

list_attributes

lab-8- list_attributes - clock

lab-8- list_attributes

3.4 Creating Clock Waveforms

lab-9 - clock waveforms-1

lab-9 - clock waveforms-2- query_clock_pin tcl

25% Duty cycle Clock

lab-9 - clock waveforms-3- 25 percentage duty cycle clock waveform

3.5 Clock Network Modelling - Uncertainty, report_timing

The process includes:

lab-10-set_clock_latency commands

lab-11-report_timing -to REGC_reg D

lab-12-set_clock_latency commands -2

lab-13-report_timing -to REGC_reg D -2

Commands:

$  report_timing -to REGC_reg/D -delay min
$ report_timing -to REGC_reg/D -delay max

3.6 IO Delays

Commands:

$ set_input_delay -max 5 -clock [get_clocks myclk] [get_ports IN_A]
$set_input_delay -max 5 -clock [get_clocks myclk] [get_ports IN_B]
$report_port -verbose
$ set_input_delay -min 1 -clock [get_clocks myclk] [get_ports IN_A]
$set_input_delay -min 1 -clock [get_clocks myclk] [get_ports IN_B]
$report_timing -from IN_A -trans -nosplit
$ set_input_delay -max 5 -clock [get_clocks myclk] [get_ports OUT_Y]
$set_input_delay -min 1 -clock [get_clocks myclk] [get_ports OUT_Y]
$report_timing -from OUT_Y -trans -nosplit
$ set_load -max 0.4 [get_ports OUT_Y]
$report_timing -to OUT_Y -cap -trans -nosplit
$ set_load -min 0.1 [get_ports OUT_Y]
$report_timing -to OUT_Y -cap -trans -nosplit -delay min

lab-14-report_port -verbose

lab-14-report_port -verbose-1

lab-15- commands - set_input_delay changes -1

lab-15- report_port_verbose after changes - set_input_delay changes -1

lab-16- commands for report_timing - gedit a command

lab-16-report_timing - gedit a command -1

lab-17- gedit file after changes - set_input_transition commands - report_timing changes commands

lab-17- set_input_transition commands - report_timing changes commands

lab-18-set_out_load commands with gedit

lab-18-set_output_delay -- 1

lab-18-set_output_delay with capacitance and trans-- 1

3.7 SDC generated_clk

Commands:

$ create_generated_clock -source reference_pin [-divide_by divide_factor] [-multiply_by multiply_factor] [-invert] source

image

Creates a generated clock in the current design at a declared source by defining its frequency with respect to the frequency at the reference pin. The static timing analysis tool uses this information to compute and propagate its waveform across the clock network to the clock pins of all sequential elements driven by this source.

The generated clock information is also used to compute the slacks in the specified clock domain that drive optimization tools such as place-and-route.

$ create_generated_clock -name MYGEN_CLK -master myclk -source [get_ports clk] -div 1 [get_ports out_clk]
$report_clocks *

lab-19-MYGEN_CLK commands-create gen command - 1

lab-19-MYGEN_CLK commands-create gen command - 2

3.8 SDC vclk, max_latency, rise_fall IO Delays

Virtual clock - purpose and timing

A virtual clock is used as a reference to constrain the interface pins by relating the arrivals at input/output ports with respect to it with the help of input and output delays.

image

$ create_clock –name VCLK –period 10

Set driving cells

It specifies the drive characteristics of input or inout ports that are driven by the cells in the technology library. These commands associate a library pin with input ports so that delay calculation can be accurately modelled.

VCLK

$ create_clock -name MYCLK -per 10

lab-20- lab8_circuit_modified file - 1

lab-20- lab8_circuit_modified file - 2

lab-20- lab8_circuit_modified file - report_clocks command - 1

lab-20- lab8_circuit_modified file - report_port -verbose command - 1

lab-20- lab8_circuit_modified file - report_port -verbose command - 2

lab-21- gedit lab14_circuit file

lab-22- read_ddc lab14 ddc - 1

lab-23 - create virtual clock - report_clocks

lab-23 - create virtual clock - report_timing -to OUT_Z

Optimizations

4.1 Combinational Optimizations

The Combinational optimization phase transforms the logic-level description of the combinational logic to a gate-level netlist.

Combinational optimization includes:

  • Technology-Independent Optimization: This optimization operates at the logic level. Design Compiler represents the gates as a set of Boolean logic equations.
  • Mapping: During this process, Design Compiler selects components from the logic library to implement the logic structure.
  • Technology-Specific Optimization: This optimization operates at the gate level.

image

lab1- combinational optimizations - opt_check- schematic view

lab1- combinational optimizations - opt_check2- schematic view

lab1- combinational optimizations - opt_check3- schematic view

lab1- combinational optimizations - opt_check4- report_timing

lab1- combinational optimizations - opt_check4- schematic view

4.2 Sequential Optimizations

Sequential optimization includes the initial optimization phase, which maps sequential cells to cells in the library, and the final optimization phase, where Design Compiler optimizes timing-critical sequential cells (cells on the critical path):

  • Initial Sequential Optimization
  • Final Sequential Optimization

lab3- seq optimizations- gtkwave-dff_const3_vcd

lab3- seq optimizations- report_area-dff_const1_v

lab3- seq optimizations- schematic view-dff_const1_vcd

lab3- seq optimizations- schematic view-dff_const3_v

4.3 Boundary Optimization

Boundary optimization results fastest critical paths and smallest design.

Basically four optimizations collectively called as Boundary optimization in synthesis (with respect to DC):

a) Inversion pushing across hierarchy. b) propagation of equal and opposite information c) propagation of unconnected /undriven ports. d) propagation of constants..

$ set_boundary_optimization u_im false

lab-4-boundary optimization-report_area

lab-4-boundary optimization-report_power

lab-4-boundary optimization-schematic

4.4 Register Retiming

Register retiming is a circuit optimization technique that moves registers forward or backward across combinational elements in a circuit. The aim of this procedure is to shorten the clock cycle or reduce circuit area. There are two basic types of register retiming: Forward retiming and backward retiming.

lab-5-register retiming - report_area - check_reg_retime

lab-5-register retiming - report_power - check_reg_retime

lab-5-register retiming - schematic view- check_reg_retime

4.5 Isolating output ports

lab-6-isolation output ports - slack time met - report_timing

lab-6-isolation output ports - with buffers

lab-6-isolation output ports - without buffers

4.6 Multicycle Paths

A Multi-Cycle Path (MCP) is a flop-to-flop path, where the combinational logic delay in between the flops is permissible to take more than one clock cycle. Sometimes timing paths with large delays are designed such that they are permitted multiple cycles to propagate from source to destination.

$set_multicycle_path -setup 2 -to prod_reg[*]/D -from [all_inputs]

$set_multicycle_path -hold 1 -to prod_reg[*]/D -from [all_inputs]

lab-7-mcp_check_v-schematic view

lab-7-mcp_check_v-slack time met - report_timing

4.7 Resource Sharing Optimizations

lab2- resource sharing optimizations - resource_sharing_mult_check- report_area

lab2- resource sharing optimizations - resource_sharing_mult_check- report_area-1

lab2- resource sharing optimizations - resource_sharing_mult_check- schematic view

Quality Checks

To start the Physical design these are the files we get input from Synthesis:

  • Netlist
  • SDC

After receiving database from synthesis team and prior to place and route you can perform some sanity checks. To validate the quality of constraints read in the netlist and the sdc file in the primetime and perform check_timing and generate report which will giving inputs like the quality of database like:

how many of the flip flops are getting clocks, how many flops are constrained, how many ports are having constrained or whether there is any violation like that which will surely give some idea about the quality of the delivered database.

In order to understand the quality of the database interms of timing , generate timing reports and understand the quality of timing how good or how bad is the database and how much you can optimize at the backend or at the placement and routing stages or what paths you cannot meet timing even during placement stages.

After analysing bit on the timing reports you can get some idea of what all areas you need to close pack during placement so that you can create regions.

Generate report_area and report_references -hier report in the designcompiler or synthesis stage to better understand the design hierarchy.

5.1 Report timing

The Report Timing command allows you to specify options for reporting the timing on any path or clock domain in the design.

In a hold timing report, the tool is checking whether the data is held long enough after the clock arrival at the clock port of the flop. i.e. if the data path is faster, the data at the flop edge can change earlier than the stipulated hold time.

Timing path is defined as the path between start point and end point where start point and end point is defined as follows: Start Point: All input ports or clock pins of a sequential element are considered as valid start point. End Point: All output port or D pin of sequential element is considered as End point.

The main goal of static timing analysis is to verify that despite these possible variations, all signals will arrive neither too early nor too late, and hence proper circuit operation can be assured. Since STA is capable of verifying every path, it can detect other problems like glitches, slow paths and clock skew.

report_timing:

lab-1- lab8_circuit_modified-report_timing - slack met

lab-1- lab8_circuit_modified-report_timing - slack met-2

lab-1- lab8_circuit_modified-report_timing - slack met-3 - for delay min

5.2 Check_timing, Check_design, Set_max_capacitance, HFN

check_timing: Checks the assertions and structure of the design for potential timing violations.This command is used to identify possible problems before generating timing or constraint reports. This command also prints which checks it performs. If a check reveals a violation, the command also prints a message about the violation. By default, the message contains a summary of the violation. To get more information about violations, use the -verbose option.

Check_design: check_design checks the current design for consistency. The check_design command checks the internal representation of the current design for consistency, and issues error and warning messages as appropriate.

Set_max_capacitance: Specifies a maximum capacitance on pins, ports or design. If maximum capacitance is set on a pin or port, the net connected to that pin or port is expected to have a total capacitance less than the specified capacitance_value. If specified on a design, the default maximum capacitance for that design is set. Library cell pins also can have max_capacitance value specified.

HFN: High Fanout Net Synthesis (HFNS) is the process of buffering the High Fanout Nets to balance the load.

en_128:

lab-2- en_128- report_area

lab-2- en_128- report_power

lab-2- en_128- schematic view

lab-2- feedthrough the design - 1

mux_generate_128_1:

lab-2- mux_generate_128_1 - report_power

lab-2- mux_generate_128_1 - report_timing - 1

lab-2- mux_generate_128_1 - report_timing - 2

lab-2- mux_generate_128_1 - schematic view - 2

lab-2- mux_generate_128_1 - schematic view

Acknowledgements

Author

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published