Beruflich Dokumente
Kultur Dokumente
Checks
Product Version Genus 17.1
November, 2017
Copyright Statement
© 2017 Cadence Design Systems, Inc. All rights reserved worldwide. Cadence and the Cadence logo are
registered trademarks of Cadence Design Systems, Inc. All others are the property of their respective
holders.
Contents
Purpose ....................................................................................................................... 4
Audience...................................................................................................................... 4
Overview...................................................................................................................... 4
Defining Terminologies ................................................................................................ 6
Conditions for the Clock-gating Checks to be Inferred................................................. 7
Setup and Hold Checks ............................................................................................... 8
Case Studies ............................................................................................................... 9
Recommendations ..................................................................................................... 15
Support ...................................................................................................................... 17
Feedback ................................................................................................................... 17
Purpose
This application note explains the following:
3. Recommendations
Audience
This document is intended for Design Engineers who are involved in the timing closure
of digital designs and want to understand clock-gating timing checks.
Overview
Clock nets toggle the most and drive large clock tree structures. Hence, switching in
clock nets can cause up to 50 percent or more of dynamic power dissipation.
The best way to reduce dynamic power dissipation is to turn the clock off when not
required. The technique of turning the clock off is called clock gating.
The following figure shows a common example of a circuit for which the synthesis tool
would employ the clock-gating technique:
It has been observed that clock gates, when placed early in the clock tree structure, can
save a lot of power.
By default, Genus requires the register bus to be a minimum of 3-bit wide to employ
clock-gating structures on the clock network. It has been observed that clock gating on
a single-bit register is not area- and power-efficient.
The clock gate checks ensure that a glitch-free and unclipped clock passes through the
clock-gating structure. The clock gate checks consist of the clock gate setup checks and
clock gate hold checks. To understand these checks, you need to be familiar with
certain terms, which are explained in the next section.
Defining Terminologies
1. Gating signal: This signal, when active, will turn the clock off.
2. Dominant or controlling state of the clock: This is the state or level of the clock
signal at which the output is controlled only by the clock signal, and is not
affected by the state of the gating signal. Hence, the clock dominates the gating
signal.
For AND, NAND clock-gating cells, the dominant state of the clock signal will be
state ‘0’. This is because the output of AND, NAND gates will not depend on the
gating signal when the clock is at state 0.
For OR, NOR gates, the controlling state of the clock will be state ‘1’.
Genus will be able to identify the dominant state from the gating cell the clock
signal drives. If the non-controlling state specified by
“set_clock_gating_check” differs from the functionality of the clock-gating
cell, Genus will flag a warning.
2. Genus can be made to recognize the clock-gating cells that were either manually
inserted or inserted by a third-party tool using the “clock gating import”
command. This command will return the total number of CG instances imported.
A. Two-input AND or NAND gates that have a clock signal driving one of the
inputs. In this case, the other pin is assumed to be the enable pin.
Note: If the other pin is a part of the test network, the Genus-LP engine
will not recognize the gate as a clock-gating instance.
A. A clock pin or a primary output port exists in the transitive fanout of the
clock gate. The tool can do tracing through pad cells.
Hold Check: This check is performed with respect to the edge of the clock that
transforms the state of the clock signal from non-controlling to controlling state.
The following figure shows the setup and hold check for ‘AND, NAND’ type gating cell.
If the data changes during the non-controlling state, it will lead to clipping of the clock as
shown in the following image:
Data
Gated CLK
Case Studies
Example 1
Consider the following definitions in the SDC:
Setup check: The output of flip flop ‘FF1’ registered at 0ns should reach pin ‘in1’ of
‘Gating cell’ prior to 4- ns.
Genus will optimize the path from flop FF1 to the gating cell such that this constraint is
met.
Hold check: The output of flip flop ‘FF1’ registered at 0ns should reach pin ‘in1’ of
‘Gating cell’ at or after 2+ ns. The PnR tool will add buffers in the clock path to meet this
requirement.
Hence, it is required that the gating signal should reach the gating cell between the time
frame of “2ns-4ns”.
In this example, if flip flop ‘FF1’ is a negative-edge-triggered flip flop, the hold check
requirement will be met as shown in the following example. However, meeting the setup
requirement will become stringent for Genus with such a design because the output of
the flip flop will now have only half the clock cycle to reach the gating signal.
Example 2
Consider the following definitions in the SDC:
In this example, the “enable” is clocked by a slow clock with a time period of 8ns. The
destination flop is clocked by a faster clock with a time period of 4ns.
Setup check: The output of flip flop ‘FF1’ registered at 0ns should reach pin ‘in1’ of
‘Gating cell’ prior to 4ns. Genus will optimize the path from flop FF1 to the gating cell to
meet this constraint.
Hold check: The output of flip flop ‘FF1’ registered at 0ns should reach pin ‘in1’ of
‘Gating cell’ at or after 2+ ns. The PnR tool will add buffers in the clock path to meet this
requirement.
Hence, it is required that the gating signal should reach the gating cell between the time
frame of “2ns-4ns”.
Hence, the setup check passes with a positive slack of 3680 ps.
The same path will fail the hold check because the “enable” will reach pin A of the clock
gate before 2ns. The backend tool will insert buffers to push the arrival of the signal in
the 2ns-4ns window.
Example 3
In this example, the “enable” is clocked by a faster clock with a time period of 4ns. The
destination flop is clocked by a slow clock with a time period of 8ns.
Setup check: In this case, Genus will choose the most restrictive time to perform the
setup check. The output of flip flop ‘FF1’ registered at 4ns should reach pin ‘in1’ of the
gating cell prior to 8ns. Genus will optimize the path from flop FF1 to the gating cell
such that this constraint is met.
In this case, the backend tool will choose the most restrictive time to perform the hold
check. The output of flip flop ‘FF1’ registered at 0ns should reach pin ‘A’ of gating cell
“g8” after 4+ ns.
Important: A paradoxical situation arises here, because as soon as the backend tool
adds buffers to meet the hold-time constraint, the setup time will get violated. The delay
added to meet the hold time should sensitize pin A of instance g8 at 4+ns, and the delay
to meet the setup is 4-ns.
The solution in this situation is a clock-gating cell with a D-glitching latch. The D-
glitching latch is clocked with the inversion of clock CLK2. This ensures that the latch
will be active only in the controlling state of clock CLK2. The tool must ensure that the
hold time for the D-glitching latch is met.
The hold check passes with the D-glitching latch as the starting point of the timing path.
Recommendations
Inferring clock-gating check on the select pin of a MUX
A clock-gating check is done with respect to the controlling level of the clock; for
example, at the rising clock edge for the AND gate.
Because the change in the clock input of the MUX does not always control the MUX
output, Genus does not create an automatic clock-gating check for the select pin. If you
need to have a clock-gating check done, you need to set a constraint using the SDC
set_clock_gating_check command:
Refer to the reference manual to know about the various options of this
command. You can remove the clock-gating checks from the specified instances
or pins.
Note: To write out this constraint in the output SDC file, you must set the
following variable:
set write_remove_cgc 1
2. set_disable_clock_gating_check
Refer to the reference manual to know about the various options of this
command.
Note: This command is supported only on the mapped instances and the pins of
the mapped instances. This command is not supported on the clock pins of an
instance.
To write this constraint in the output SDC file, you must set the following variable:
set write_disable_and_rmdisable_cgc 1
3. Genus creates an external delay and breaks the timing path on the pin on which
Genus infers the clock-gating check.
To disable the timing check on a pin, you can direct the tool to disable the
breaking of the timing path. Here is an example:
4. To restore the clock-gating checks inferred on the specified pins or the enable
pins of the specified instances that were present before applying the
set_disable_clock_gating_check command, use the following command:
Note: This command is supported only on the mapped instances and the pins of
the mapped instances. This command is not supported on the clock pins of an
instance.
To write this constraint in the output SDC file, you must set the following variable:
set write_disable_and_rmdisable_cgc 1
Support
Cadence Support Portal provides access to support resources, including an extensive
knowledge base, access to software updates for Cadence products, and the ability to
interact with Cadence Customer Support. Visit https://support.cadence.com.
Feedback
Email comments, questions, and suggestions to content_feedback@cadence.com.