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

Common Power Format 1.

1
Tutorial

October 2009

Qi Wang
Cadence Design Systems, Inc.
LPC Vice Chair, LPC, Si2

Innovation Through Collaboration


CPF 1.1 is a Si2 Standard released in September 2008.

This tutorial is targeted for audience with basic


knowledge of Si2 Standard CPF 1.0. For more
information on CPF 1.0 and related training materials,
please visit the following links:

http://www.si2.org/?page=811 (CPF 1.0 Spec)


http://www.si2.org/?page=905 (CPF 1.0 Pocket Guide)
http://www.si2.org/?page=907 (CPF 1.0 Tutorials)

Innovation Through Collaboration – Low Power Coalition –2–


Highlights of New Features

● Hierarchical flow for IP reuse


● Macro modeling
● Modes and transitions
● Derived and base power domains
● Isolation
● Level shifter
● State retention
● Others

Innovation Through Collaboration – Low Power Coalition –3–


Hierarchical Flow Support
● Objectives
‹ Enable IP reuse
‹ Reuse Design Hierarchy and better organization.
‹ Enable Low power Custom IP Integration and verification.
‹ Support Bottom-up and Top Down Flow

● Ensures
‹ Consistent Representation
‹ Consistent Integration style
‹ Consistent Verification
‹ Consistent Rules, semantics, precedence policy.

Innovation Through Collaboration – Low Power Coalition –4–


Soft IP Reuse

● IP is defined with multiple power structures and functionalities


‹ Can use any command to describe a block level power intent
‹ Simulation and static verification can be performed at the block design level before
chip level integration and fixes can be made earlier with less schedule impact.

● Top level and block level power structures are linked together using
power domain mapping
‹ Multiple levels of hierarchy are supported

● Main Features
‹ Merge and reconfigure power domains
‹ Reconfigure power rules
‹ Resolve precedence
‹ Integrate power modes

Innovation Through Collaboration – Low Power Coalition –5–


Power Domain Mapping

● Power domain mapping is the merging of a power domain at an upper


scope with another power domain at a lower scope
● Semantics of domain mapping can be well defined
‹ Not all domains can be merged together
¾ Block level switchable domain can only be mapped into top level switchable
domain if the shutoff conditions are the compatible
‹ Precedence rules of domain merging
¾ Top level domain rules cannot overwrite low level domain rules, etc.
‹ Power modes integration
¾ Domain states in block level power mode definition must be consistent with the
power mode definitions of the mapped domain

Innovation Through Collaboration – Low Power Coalition –6–


Hierarchical Flow Related Extensions

set_instance [ { instance | -instances_of_all_cell cell }


[-port_mapping port_mapping_list]
[-domain_mapping domain_mapping_list]
[-parameter_mapping parameter_mapping_list]

set_design module [-ports port_list]


[-honor_boundary_port_domain]
[-parameters parameter_value_list]

get_parameter parameter_name

include

Innovation Through Collaboration – Low Power Coalition –7–


Hierarchical CPF Example: Block Level CPF

Block1

I1 I2

Iso Rule
un- External
switched Switchable
(PDOn) (PDExt)

set_design Block1 –ports { IsoExt }


create_power_domain –name PDOn –instances { I1 } -default
create_power_domain –name PDExt –instances { I2 }
create_isolation_rule -name Iso1 –from PDExt –to PDOn\
–isolation_condition IsoExt
create_nominal_condition –name on –voltage 1.0 –state on
create_nominal_condition –name off –voltage 0 –state off
create_power_mode –name all_on –domain_conditions { ON@on Ext@on}
create_power_mode –name ext_off –domain_conditions { ON@on Ext@off}
end_design
Innovation Through Collaboration – Low Power Coalition –8–
Hierarchical CPF Example: Top Level CPF

set design Top Switch


un-
switched Internal
Switched
X1 X2

I1 I2 I1 I2

Iso Rule
Iso Rule
un- External un- External
switched Switchable swithced Switchable

set design Block1 set design Block1

include Block1.cpf
set_design Top –ports { Iso Pwr }
create_power_domain –name AON
create_power_domain –name Int –shutoff_condition { !Pwr }
set_instance X1 –domain_mapping { { PDOn AON } { PDExt AON } } –design Block1
set_instance X2 –domain_mapping { { PDOn AON } { PDExt Int } } –design Block1 \
-port_mapping { {IsoExt Iso} }
end_design

Innovation Through Collaboration – Low Power Coalition –9–


Hierarchical CPF Example: Integrated View

Top Switch
un-
switched Internal
Switched
X1 X2

I1 I2 I1 I2

Iso Rule
un- un- Internal
un-switched
switched switched Switched

Block1 Block1

low level isolation rule is not


required due to domain
low level domains are merged
reconfiguration
to the same domain at top

low level isolation rule is


promoted to the top

Innovation Through Collaboration – Low Power Coalition – 10 –


Reusable IP Example – IP description

myIP Specify virtual ports: port save and


restore do not exist in RTL
externally
Switched

State Specify parameters: declare parameter


Retention
one_ctrl with default value 0.
set_design myIP -ports { save restore} \
-parameters { {one_ctrl 0}}
create_power_domain –name PD –default externally switchable domain
if { [get_parameter one_ctrl] == “0” } {
create_state_retention_rule –name sr\ Use parameters: use the parameter
–instances foo*\ like a string variable
-save_level save –restore_level restore
} else {
create_state_retention_rule –name sr \
–instances foo* \
-restore_edge restore
}
end_design

Innovation Through Collaboration – Low Power Coalition – 11 –


Reusable IP Example – IP Usage
configure the IP to specify the top level
use single control driver for the virtual
use the IP in a
retention (overwrite the ports
Instantiate IP CPF model switchable domain
default parameter value)
include myIP.cpf ;#load in the CPF model for IP
set_design top
top I1
create_power_domain –name PDBlue –default
myIP1 create_power_domain –name PDRed \
internal –shutoff_condition pcm/pso –base_domains PDBlue
switchable set_instance I1/myIP1 –design myIP \
(PDRed) -domain_mapping { {PD PDRed}} \
pso myIP2 -port_mapping { {restore pcm/restore}} \
PCM -parameter_mapping { {one_control 1}}
restore
set_instance myIP2 –design myIP \
unswitched –domain_mapping { {PD PDBlue}}
(PDBlue) end_design

Instantiate the same IP CPF


use the IP in an
model in another instance
always-on domain

Innovation Through Collaboration – Low Power Coalition – 12 –


Top Level Integrated View

top I1
top I1
myIP1 myIP1
internal
switchable
(PDRed)

pso myIP2
PCM pso myIP2
restore PCM
restore
unswitched
(PDBlue)
unswitched
(PDBlue)

Before Integration After Integration

Innovation Through Collaboration – Low Power Coalition – 13 –


Hard IP Support: Macro Model
● Accurate simulation, implementation, and verification of custom
IP blocks or macros, such as embedded RAM, can be
accomplished by defining the power features using
set_macro_model <name>
“power information content”
end_macro_model
● This independent definition provides verification and
implementation tools the power information necessary to
implement and verify designs using these custom IP blocks.
● Another benefit of the macro model definition is that it allows
the original IP block behavioral model to co-exist with the CPF
definition to enable power aware verification at the design level.

Innovation Through Collaboration – Low Power Coalition – 14 –


Macro Model Definition
● Define a custom IP block as a macro model it contains one or
more of the following features:
‹ Complete power domain support
¾ internally switchable, externally switchable, un-switched
‹ Power mode definition
‹ Input and output boundary isolation
‹ State retention for switchable domains
‹ Feed-through ports
‹ Floating ports

● Macro models must be black boxed for implementation and


Conformal verification, example would be an embedded RAM
● Macro models are not black boxed for simulation

Innovation Through Collaboration – Low Power Coalition – 15 –


Macro Model Example

VDD
D1
● Multiple power ports (VDD, VPP)
iso1
Switches ● Different types of domains
iso2 Un-
switched Internally ● Domain with retention

Isolation
ret (AON) Switched D4 ● Domain without retention
pwr (PSO)
State ● Inputs isolated (D3)
D2 Retention
● Inputs not isolated (D2)
Isolation
● Outputs isolated (D4)
● Outputs not isolated (D5)
Isolation

D3
Externally ● Internal crossing with isolation
Switched D5
NC
● Feed-through (F1, F2)
(EXT)
F1
● Floating port (NC)
F2 VSS VPP

Innovation Through Collaboration – Low Power Coalition – 16 –


Macro Model Related Extensions

set_macro_model macro_cell_name

end_macro_model

set_wire_feedthrough_ports list_of_ports

set_input_voltage_tolerance –ports list_of_ports –max_bias voltage

set_floating_ports list_of_ports

set_instance … -model <model> ….

Innovation Through Collaboration – Low Power Coalition – 17 –


Macro Model Basics
● Make sure all input and output pins are assigned to the correct
domain
‹ An input pin assigned to a domain means the logic driven by the input
pin inside the macro cell takes the power supply from this domain
‹ An output pin assigned to a domain means the logic driving the output
pin inside the macro cell takes the power supply from this domain
● If a domain contains registers defined in the behavioral model,
declare the registers in the domain definition using –instances
option
● Do not make an internal switchable domain as the default
domain for the macro model.
‹ Choose an un-switched domain or an external switchable domain as the
default domain of the macro model
¾ To avoid power shutoff behavior applied to unexpected behavioral
code during simulation

Innovation Through Collaboration – Low Power Coalition – 18 –


Defining Macro Domains
create_power_domain –name PSO -shutoff_condition !pwr \
-base_domains AON -boundary_ports { D2 } -instances mem*

notes on domain PSO


‹ active low input “pwr” turns power off VDD
D1
‹ port D2 is associated with PSO
iso1
‹ switch source is AON domain Switches
iso2 Un-
switched Internally

Isolation
ret Switched
(AON) D4
create_power_domain -name AON –default \ pwr
State
-boundary_ports { D1 D4 iso* ret pwr} D2 Retention
update_power_domain –name AON \ Isolation

–primary_power_net VDD \

Isolation
–primary_ground_net VSS D3 Externally
Switched
NC (EXT) D5

F1
create_power_domain –name EXT \
F2 VSS VPP
-boundary_ports { D3 D5 }
update_power_domain –name EXT \
notes on domain EXT
-primary_power_net VPP \ ‹ port D5 is associated with EXT

-primary_ground_net VSS

Innovation Through Collaboration – Low Power Coalition – 19 –


Defining Isolation Rules

● Inputs are NOT isolated inside the macro model but it requires
isolation when the drivers can be switched off in the design
context\
‹Define an isolation rule for the input ports without isolation condition and
with “isolation_output” to define what the valid “clamp” value should be
when the driver is switched off.

● Internal domain crossings


‹Isolation of macro internal domain crossings are expected to be part of
the behavioral model. However, the isolation control condition in the
isolation rules could be by simulation tool to generate automatic assertions
to catch illegal power sequences.

● Inputs or outputs isolated inside the macro model


‹Define isolation rule with -isolation_condition and -isolation_output.
Condition must be expressed as a macro input port.

Innovation Through Collaboration – Low Power Coalition – 20 –


Defining Isolation
VDD
create_isolation_rule –name IsoOut \ D1
-from PSO –pins { D4 } \ iso1
Switches
–isolation_condition !pwr \ iso2 Un-
switched Internally

Isolation
ret Switched
–isolation_output high (AON) D4
pwr
notes on rule IsoOut State
D2
‹ port D4 belongs to the default domain AON Retention
Isolation
create_isolation_rule –name IsoInReq \
–to PSO –pins { D2 } \

Isolation
D3 Externally
–isolation_output low Switched
NC (EXT) D5
notes on rule IsoInReq F1
‹ D2 has no internal isolation. The rule specify a F2 VSS VPP
constraint: if D2 is driven by a switchable domain
(after instantiated at top), it needs to be isolated to low create_isolation_rule –name IsoInt \
when the domain is off
–from EXT –to PSO \
create_isolation_rule –name IsoIn \ –isolation_condition iso2 \
–to EXT –pins { D3 } \ –isolation_output low
–isolation_condition iso1 \ notes on rule IsoInt
–isolation_output low ‹ This rule covers an internal crossing
notes on rule IsoIn
‹ port D3 belongs to the domain EXT

Innovation Through Collaboration – Low Power Coalition – 21 –


Defining State Retention

VDD
create_state_retention_rule –name PSO_RET \ D1
-domain PSO –secondary_domain AON \ iso1
Switches
iso2 Un-
-save_edge ret switched Internally

Isolation
ret Switched
(AON) D4
pwr
State
notes on state retention rule D2 Retention
‹ Use the register names in –instances if you want Isolation
to apply the rule only to those registers

Isolation
‹ No need to use update_state_retention_rule D3 Externally
Switched
‹ AON domain is the secondary domain of the NC (EXT) D5
retention logic by default F1

F2 VSS VPP

Innovation Through Collaboration – Low Power Coalition – 22 –


Defining Feed-through Ports

notes on defining feed-through ports


VDD
‹ must not have internal drivers D1

‹ may not be defined in multiple groups, i.e. the iso1


Switches
iso2 Un-
same pin can not appear in two feed through switched Internally

Isolation
ret Switched
(AON) D4
commands pwr
State
D2 Retention
Isolation

Isolation
D3 Externally
Switched
NC (EXT) D5
set_wire_feedthrough_ports { F1 F2 } F1

F2 VSS VPP

Innovation Through Collaboration – Low Power Coalition – 23 –


Defining Floating Ports

notes on defining floating ports


VDD
‹ not associated with any domain
D1
‹ are ignored during verification iso1
Switches
iso2 Un-
switched Internally

Isolation
ret Switched
(AON) D4
pwr
State
D2 Retention
Isolation

Isolation
D3 Externally
Switched
NC (EXT) D5
set_floating_ports { NC }
F1

F2 VSS VPP

Innovation Through Collaboration – Low Power Coalition – 24 –


Usage of the Macro Model in Design

● The macro or hard IP cell is instantiated in RTL or netlist


‹ Non floating instance input must connect to nets in the design
‹ Power and ground nets may be connected in pre P&R design data, but that is not
required and is ignored in analysis
‹ Power and ground nets must be connected in post P&R netlists
● Macro model power domains are integrated with parent block power
domains via -domain_mapping option
‹ Domain mapping specifies which top level domain provides power supply to a block
level domain
‹ P&R should connect power/ground pins of the macro cell to the parent block
power/ground nets based on domain mapping
‹ Verification tools should check power/ground nets of the parent block connect to the
correct macro instance ports
‹ Simulation should exercise the power behavior of the macro model based on the
parent block or test bench domains that the macro model power domains are mapped
to

Innovation Through Collaboration – Low Power Coalition – 25 –


Integrate Macro Model At Top
set_design top
VDD

create_power_domain –name PDBlue –default

update_power_domain –name PDBlue \ I1 VDD


-primary_power_net VDD \ D1
Un- iso1
-primary_ground_net VSS switched Switches
iso2 Un-
(PDBlue) switched Internally

Isolation
ret Switched
(AON) D4
create_power_domain –name PDRed \ pwr
State
–shutoff_condition pso \ Switches D2 Retention
-default_isolation_condition I1/iso1 \ Internally Isolation
Internally
-base_domains PDBlue Switched
Switched

Isolation
-instances … (PDRed) D3 Externally
State Switched
NC (EXT) D5
Retention
update_power_domain –name PDRed \ F1

-primary_power_net VDD_SW F2 VSS VPP

-primary_ground_net VSS

……
end_design

Innovation Through Collaboration – Low Power Coalition – 26 –


Power Domain Mapping of Macro Model
VDD
set_design top
create_power_domain –name PDBlue –default

update_power_domain –name PDBlue \


VDD
-primary_power_net VDD \
D1
-primary_ground_net VSS Un- iso1
switched Un- Switches
iso2 Always
switched
(PDBlue)

Isolation
On
(AON) Internally
create_power_domain –name PDRed \ ret
pwr
Switched D4
–shutoff_condition pso \ State
-default_isolation_condition I1/iso1 \ Switches D2 Retention
-base_domains PDBlue Internally
-instances … Switched

Isolation
Externally
(PDRed) D3 Externally D5
Switched
State NC Switched
(EXT)
update_power_domain –name PDRed \
Retention F1
-primary_power_net VDD_SW
-primary_ground_net VSS F2 VSS VPP

set_instance ipInst –domain_mapping \


{ {AON PDBlue} {EXT PDRed}}
VSS
include macro.cpf
end_design

Innovation Through Collaboration – Low Power Coalition – 27 –


Integration of Macro Cell At Top
connect power
VDD
no isolation needed: the driver is already
isolated

VDD
no isolation needed: there is no domain D1
crossing, i.e. both drivers and receivers are Un- iso1
in the same domain switched
iso2 Un-
Switches
(PDBlue) switched Internally

Isolation
ret Switched
(AON) D4
pwr
isolation may be needed: if the driver State
Switches D2 Retention
domain can be off while the receiver is on,
Isolation
need to have an isolation rule at top level for Internally
Internally
isolation insertion Switched
Switched

Isolation
(PDRed) D3 Externally
Switched
State NC (EXT) D5
No isolation needed: pin D3 is isolated Retention
F1
internally and the crossing is not a domain VSS VPP
F2
crossing because domain PDRed merged
with domain EXT

No isolation needed: NC is a floating pin VSS


connect ground
No isolation needed: F1 and F2 are internal
feed-through. At top, the driver and receiver
of the net are in the same domain
Innovation Through Collaboration – Low Power Coalition – 28 –
Level Shifters Within Macro Cell
● There is no need to describe level shifters between internal domain
crossing.
● To describe level shifters at the boundary ports a macro cell, assign
the port to the proper power domain in the macro model
‹ Do not create level shifter rules in a macro model
‹ See also the slide Macro Model Basics
VDD_EXT VDD

Declare port O
Declare port I belonging to the
belonging to the power domain
power domain corresponding to
corresponding to VDD_EXT
VDD_EXT I
Core
O

level shifters
Innovation Through Collaboration – Low Power Coalition – 29 –
Improved Power Mode and
Mode Transition Modeling
● In addition to ‘on’ and ‘off’ state, included new ‘standby’ state
‹ A state where cells can maintain its value but cannot support computation
‹ A ‘standby’ state can be achieved by source biasing or reverse body biasing
● Be able to define states of a power domain along with the conditions to
enable
● Be able to specify mode transition time and domain transition time when a
mode transition happens

Innovation Through Collaboration – Low Power Coalition – 30 –


Power Mode/Transition Related Extensions

create_nominal_condition -name string


-voltage float [-ground_voltage float]
[-state {on | off | standby}]
[-pmos_bias_voltage float] [-nmos_bias_voltage float]

create_power_domain -name power_domain ……


[-active_state_conditions list_of_domain_active_state_conditions]
Example:
-active_state_conditions {1.0v@vdd_low_en 1.2v@{!vdd_low_en}}

update_power_domain -name domain


{…| -transition_slope [float:]float |
| -transition_latency {from_nom latency_list}
| -transition_cycles {from_nom cycle_list clock_pin} }

Innovation Through Collaboration – Low Power Coalition – 31 –


Secondary Power Domain

Always-on(Constant)
Follow pin connected to Power
switchable power
(primary power net) Switched Cells Physical View

Secondary power pin


connected to always-
on power

Always on domain
PD1

Logical View
Switchable domain
PD2

PD2 is a derived power domain of PD1 Always on instance


PD1 is the secondary domain of PD2
Innovation Through Collaboration – Low Power Coalition – 32 –
Secondary Power Pin

● Additional power/ground pin other than the follow pins in standard cell
technology.
● Special low power cells:
‹ Always on
‹ Isolation
‹ State retention
‹ level shifter
‹ power switch cell
‹ …

Innovation Through Collaboration – Low Power Coalition – 33 –


Modeling of Secondary Power Domain

● Always-on instance
‹ There is no absolutely always on.
‹ An always-on instance is on/off in sync with the secondary power domain.
¾ If the corresponding secondary power domain is shut off, the always-on
instance is off.
● Retention instance
‹ Retention cell’s state is retentive in sync with its secondary power domain
‹ Modes of operation
¾ “On” state
ƒ Both primary and secondary domain are on
¾ Retention state
ƒ Primary domain is off but secondary domain is on
¾ Deep-sleep state
ƒ Both primary and secondary power domain are off

Innovation Through Collaboration – Low Power Coalition – 34 –


Secondary Power Domain
Related Commands

identify_secondary_domain –secondary_domain power_domain


{–instances instance_list | -cells cell_list } \
[ -domain power_domain [-from power_domain | -to power_domain]]

create_state_retention_rule –name string ….


[-secondary_domain power_domain]

create_power_switch_rule –name string …


[-secondary_domain power_domain]

Innovation Through Collaboration – Low Power Coalition – 35 –


Isolation Enhancements

● Support IP level isolation constraint


‹ Create an isolation rule with neither –isolation_condition nor –no_condition
● Support isolation cells without enable control
● Isolation rule with tristate isolation output
● Isolation insertion at arbitrary locations in the hierarchy
‹ Specified on update_isolation_rule
‹ Must be in appropriate power domain

Innovation Through Collaboration – Low Power Coalition – 36 –


Isolation Enhancements
Related Commands

define_isolation_cell –cells … [-no_enable { high | low | hold} ]

create_power_domain -name power_domain ……


[ -default_isolation_condition expression]

create_isolation_rule -name string -isolation_condition expression …..


[-isolation_output {high|low|hold|tristate}] [-no_condition]

update_isolation _rules -names rule_list …


-within_hierarchy instance}

Innovation Through Collaboration – Low Power Coalition – 37 –


Level Shifter Enhancements

● Be able to instantiate the isolation logic in any logic hierarchy within a


power domain

update_level_shifter_rules -names rule_list \


{ -location { from | to} | -within_hierarchy instance} | \
-cells cell_list | -prefix string }...

Innovation Through Collaboration – Low Power Coalition – 38 –


State Retention Enhancements

● Latch support
● Differentate rules for level sensitive save/restore retention from edge-
sensitive ones
● Gate level simulation
‹ Identifies elements in simulation models that is on when the secondary supply is on
and primary supply is off
● Exclude option
‹ Easier granulation to identify registers for SR

Innovation Through Collaboration – Low Power Coalition – 39 –


State Retention Enhancements
Related Commands

define_state_retention_cell -cells cell_list …


-restore_function expression
[-restore_check expression]
[-save_function expression]
[-save_check expression ]
[-always_on_components component_list]

create_state_retention_rule -name string …… [-exclude instance_list]


[ { -restore_edge expression | -restore_level expression }
[ { -save_edge expression | -save_level expression } ]]
[-target_type { flop | latch | both} ]

Innovation Through Collaboration – Low Power Coalition – 40 –


Verification Related Exhancements

● Be able to specify illegal power modes


assert_illegal_domain_configuration ….
● Assertion control
‹ Control of existing non-power aware assertions during power events
‹ Either by name or by domain
‹ Control of impact – reset or suspended
create_assertion_control -name string
{ -assertions assertion_list | -domains power_domain_list}
[ -shutoff_condition expression ] [-type {reset | suspend} ]

Innovation Through Collaboration – Low Power Coalition – 41 –


Other Enhancements

● Support physically disjoint power domain


‹ Logically one power domain but physically located in different regions
‹ Power nets can be share or may not be shared

update_power_domain -name domain


{ … -equivalent_power_nets list_of_power_nets
| -equivalent_ground_nets list_of_ground_nets } ...

● Handle equivalent control pins for power control signals


‹ Isolation, retention and power switch enables may be broken into multiple signals with
non-overlapping sequence to reduce rush current

set_equivalent_control_pins –master pin –pins pin_list


{ -domain domain | -rules rule_names}

Innovation Through Collaboration – Low Power Coalition – 42 –


CPF 1.1 Related Information

● CPF 1.1 Document http://www.si2.org/?page=811


● CPF 1.1 Parser http://www.si2.org/?page=811
● Si2 Low Power Coalition (LPC) http://www.si2.org/?page=726
● Power Forward Initiative http://www.powerforward.org
● Practical Guide to Low Power Design
http://www.powerforward.org/lp_guide/

Innovation Through Collaboration – Low Power Coalition – 43 –

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