Вы находитесь на странице: 1из 6

set_switching_activity

NAME
SYNTAX
ARGUMENTS
DESCRIPTION
EXAMPLES
SEE ALSO

NAME
set_switching_activity

Sets the switching activity annotation on nets, pins, ports and cells of the
current design.

SYNTAX
status set_switching_activity
[-static_probability static_probability]
[-toggle_rate toggle_rate]
[-state_condition state_condition]
[-path_sources path_sources]
[-rise_ratio rise_ratio]
[-period period_value | -base_clock clock]
[-type object_type_list]
[-hierarchy]
[object_list]
[-verbose]

Data Types
static_probability float
toggle_rate float
state_condition string
path_sources list
rise_ratio float
period_value float
clock string
object_type_list list
object_list collection

ARGUMENTS
-static_probability static_probability

Specifies the static probability value. The static probability is a floating


point number between 0.0 and 1.0. It represents the percentage of the
time the signal is at logic 1. For example, a static probability value of 0.25
indicates that the signal is at logic 1 for 25% of the time.

-toggle_rate toggle_rate
Specifies the toggle rate value. The toggle rate is a positive floating point
number that represents the number of 0->1 and 1->0 transitions that the
signal makes during a period of time. The period is by default 1 unit and
can be specified with the -period option. The time unit defined in the
library is used as the time unit. Alternatively, a related clock can be
annotated using the -base_clock argument, and the specified toggle rate
will be relative to the related clock period.

-state_condition state_condition

Specifies the state condition when annotating state-dependent toggle


rates on pins or state-dependent static probabilities on cells. State
dependent toggle rates can be annotated when the internal power of the
library cell pin is characterized with state-dependent power tables. State-
dependentstatic probabilities can be annotated when the cell leakage
power is characterized with state-dependent power tables. The state
condition specified with this argument must be logically equivalent to a
state condition in the internal or leakage power characterization.

-path_sources path_sources

Specifies the path sources when annotating path-dependent toggle rates


on pins. This can be used when the library cell pin has path-
dependentinternal power characterization. The path sources specified with
this argument must be the same as those in the internal power
characterization.

-rise_ratio rise_ratio

Specifies the ratio of rise transitions to total transitions for the specified
toggle rate when annotating pins that are characterized with both rise and
fall internal power. The rise_ratio argument is a floating point number
between 0.0 (all transitions are falling) and 1.0 (all transitions are rising).
You need to specify a toggle rate in order to use this option. The default
value is 0.5.

-period period_value

Specifies the time period for which the number of transitions given in the
toggle rate -toggle_rate occur. The time units for this value are those
specified in the main technology library. When this argument is used,
the -toggle_rate specified by the -toggle_rate argument is divided by
the given -period_value; The resulting toggle rate is then annotated to
the object(s) specified with the set_switching_activity command. If
the -periodargument is not specified, a default value of 1.0 is assumed.

-base_clock clock
Specifies a clock to which toggle_rate is related. This clock is referred to
as the object's related clock. When specified, the related clock is
annotated to the design objects, and during power calculations the
annotated toggle rate value is divided by the related clock period. The
resulting toggle rate is then used for calculating power. The clock period
can be changed between different runs of report_power and the
resulting change in the toggle rate of the design objects will be used
automatically without re-annotating the switching activity. You can also
specify "*" as the clock value of the -base_clock argument. This
specifies that Power Compiler will infer the related clock on the design
object automatically before power calculations.

-type object_type_list

Specifies a list of object types that will be used for implicitly selecting the
objects that will be annotated with the specified switching activity
information. The object_type_list argument can be a list of one or more of
the following object types:
registers (sequential cell outputs),
tristates (tristate cell outputs),
black_boxes (black box cell outputs),
inputs (input design ports or hierarchical instance pins),
outputs (output design ports or hierarchical instance pins),
inouts (inout design ports / hierarchical instance pins),
ports (design port or hierarchical instance pins),
nets (nets),
regs_on_clocks clock_list (outputs of flip-flips clocked by the clocks in clock_list),
clock_gating_cells (clock gating cell outputs),
memory (memory cell outputs).

When the -type argument is used all the objects in the current instance (
or current design, if current instance is not set) that satisfy the selection
criteria will be annotated with the specified switching activity. If
the registers or regs_on_clocks selection type is used, both the non-
inverting (Q) and inverting (QN) sequential cell outputs are annotated.
The non-inverting outputs are annotated with the specified toggle rate
and static probability. The inverting outputs are annotated with the
specified toggle rate. The annotated static probability on the inverting
outputs is 1.0 - sp_val where sp_val is the specified static probability.
The regs_on_clocks selection type needs the argument clock_list which
is a list of clock names. This selection type selects all the registers that
are clocked by a clock whose name is in clock_list. A register is clocked by
a clock clk if the clock pin of the register is in the transitive fanout of the
source port or pin of the clock clk. Note that although
the registers selection type applies to both flip-flopsand latches,
the regs_on_clock selection type applies only to flip-flops. Both
the registers and regs_on_clocks selection types exclude clock-
gatingcells, that might have internal latches and are therefore sequential
cells.
Note that the object_list argument for explicitly specifying the objects to
be annotated, and the -type argument for implicitly specifying the objects
to be annotated, are mutually exclusive.

-hierarchy

Used with the -type argument and specifies that all the objects in all the
hierarchy that satisfy the selection criteria will be annotated. When this
option is not specified, only the top level objects in the current instance
are considered.

object_list

Specifies a list of nets, pins, ports or cells in the current design on which
the -static_probability and -toggle_rate switching activity values are
to be set.

Note that the object_list argument for explicitly specifying the objects to
be annotated.

If the object is a hierarchical cell, it is used with the -type argument and
specifies that all the objects in the hierarchical cell that satisfy the
selection criteria will be annotated.

-verbose

Provides a more verbose output when switching activity is annotated.

DESCRIPTION
This command can be used to annotate design nets, ports, pins and cells
with the different kinds of switching activity. These include simple toggle
rate and static probability on nets, ports and pins; state and path
dependent toggle rates on cell pins, and state dependent static
probabilities on cells.

Toggle rates and static probabilities are annotated using the -


toggle_rate and -static_probability arguments respectively. The
toggle rate and static probability can be made state dependent by
specifying the state condition with the -state_dep argument. The toggle
rate can be made path dependent by specifying the path sources with
the -path_sources argument. A related clock can be specified using
the -base_clock argument. The annotated toggle rate is divided by the
related clock period during power calculation to calculate the effective
toggle rate. When none of the -toggle_rate, -static_probability and -
base_clock arguments are given, then annotated switching activity is
removed from the specified objects.
The design objects that will be annotated with switching activity can be
specified explicitly and implicitly as a list of objects. The objects can also
be specified implicitly by the -type and -hierarchy arguments.

For statistics on the switching activity annotation on the current design,


use the report_saif command.

Multicorner-Multimode Support

This command applies to the current scenario only.

EXAMPLES
The following set_switching_activity command annotates a simple
toggle rate value of 33 / 1320 = 0.025 and a static probability value of
0.015 to all design input ports.
prompt> set_switching_activity -toggle_rate 33 -period 1320 \
-static_probability 0.015 [get_inputs]

The following example annotates a toggle rate value of 0.25 and a static
probability value of 0.015 to all design input ports. The clock CLK is
specified as the related clock for all inputs. When calculating the power,
the annotated toggle rate value (0.25) is divided by the related clock
period (10) and the resulting toggle rate (0.025) is used.
prompt> create_clock CLK -period 10
prompt> set_switching_activity -toggle_rate 0.25 -base_clock CLK \
-static_probability 0.015 -type inputs

The following example annotates state-dependent static probabilities on


the cell or1:
prompt> set_switching_activity -static_probability 0.10 \
-state_condition "A & B" [get_cell or1]
prompt> set_switching_activity -static_probability 0.35 \
-state_condition "A & ! B" [get_cell or1]
prompt> set_switching_activity -static_probability 0.25 \
-state_condition "! A & B" [get_cell or1]
prompt> set_switching_activity -static_probability 0.30 \
-state_condition "! A & ! B" [get_cell or1]

The following example annotates simple and path-dependent toggle rates


on the Y output pin of the cell xor1:
prompt> set_switching_activity -toggle_rate 0.022 \
[get_pin xor1/Y]
prompt> set_switching_activity -toggle_rate 0.020 \
-path "A" [get_pin xor1/Y]
prompt> set_switching_activity -toggle_rate 0.002 \
-path "B" [get_pin xor1/Y]

The following example removes the switching annotation from all


sequential cell outputs in the current design:
prompt> set_switching_activity -type registers -hierarchy

The following example annotates switching activity on all the registers in


the current design that are clocked by the clk1 or clk2 clocks.
prompt> set_switching_activity -toggle_rate 0.1 \
-static_probability 0.5 \
-type {regs_on_clock {clk1 clk2}} -hierarchy

The following example annotates all primary inputs with a toggle rate of
0.2, a static probability of 0.5, and a related_clock attribute with a value
of "*". When power is calculated during the report_power command,
the related clocks on the design inputs are inferred automatically and the
toggle rate value of 0.2 is scaled by the related clock period.
prompt> set_switching_activity -toggle_rate 0.2 \
-static_probability 0.5 -base_clock "*" \
-type inputs
prompt> report_power

Вам также может понравиться