Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
TI VE
Problem Statement
Robust and easyy to use db access mechanisms p
play
ya
huge role in defining how productive users of design
systems can be
Historically,
Hi t i ll E
Encounters
t db access h
has b
been powerful
f l
and fast, but a bit cryptic and difficult to learn
In 7.1,, a new db access mechanism was introduced
which minimizes the need to peruse the 2000+ FE-TCL
commands and condenses them into 2 commands:
dbGet and dbSet
Cadence Confidential
dbGet: Goals
Approach
Use a methodology similar to what is available to DFII-SKILL with
the ~> operator
Enhance it with some new options not found in SKILL
3
Cadence Confidential
setDbGetMode/getDbGetMode
dbSchema
db a s o
dbTransform
dbQuery
dbShape (available in 10.1)
Cadence Confidential
What is this thing I have selected? Select an instance graphically and then:
Cadence Confidential
dbGet Examples:
dbget top.insts.cell.name
AND2 OR2 INV1 AND2
Cadence Confidential
dbGet Examples:
p
.?h
Similar to .? but includes type, legal enum values, and a short description
For obj or objList includes objType
Note,, objType
j yp field itself is suppressed
pp
as too long,
g, with comment how to see it
Alphabetical
Cadence Confidential
Value matching
encounter 1> dbGet top.nets.name *clk*
a_clk1 clk2 clk3 clk[1] clk_2
encounter 2> dbGet top.nets.name *clk?
a clk1 clk2 clk3
a_clk1
Field name matching (for .? .?? .?h) also useful to get just one field
encounter 1> dbGet top.insts.?h pstat*
pStatus(settable): enum(cover fixed placed unplaced), Instance
placement status
Cadence Confidential
dbGet Examples: p
p with Pattern Matching
The p
p option
p
returns the p
pointer of the object
j
rather
than the field value, so pointers of objects that match a
field value can be returned
The
Th p2
2 option
ti goes b
back
k 2 llevels
l off objects,
bj t -p3
3 goes
back 3 levels, etc.
encounter 1> dbGet top
top.nets.name
nets name *clk*
a_clk1 clk2 clk3
# all nets matching *clk*
encounter 2> dbGet p top.nets.name *clk*
0x111111 0x222222
# ptrs to nets matching *clk*
encounter 3> dbGet [dbGet -p top.insts.cell.name INVX1].name
INVX1 INVX1 INVX1
# all INVX1 cells in design
encounter 4> dbGet [dbGet p2 top.insts.cell.name INVX1].name
i1/i2 i1/i3 i4/i5/i6
# all inst names of INVX1 in design
Cadence Confidential
10
Cadence Confidential
11
Cadence Confidential
12
Cadence Confidential
Cadence Confidential
>dbGet $n.allTerms.name
#$n is clk net attached to term
clk i1/i2/clkIn
#combo of terms and instTerms
>set i [dbGet $n.allTerms.inst]
$n allTerms inst]
ERROR: "inst" - Invalid obj/attribute for term
0x0 0x111111
#term has no inst field, so 0x0
>dbGet $i.name
0x0 i1/i2x
#no error msg from 0x0.name
>dbGet $i.name i1*
i1/i2x
>dbGet $i.name *x*
#0x0 is not a name, so *x* does
i1/i2x
>dbGet $i.name 0*
#no name was matched at all, so
0x0
14
Cadence Confidential
and instTerm
returned
15
Cadence Confidential
By default, all distance values in um rather than dbu (use d for dbu)
A few object names have been changed to align better with Virtuoso
and OpenAccess terminology. For example:
term in dbGet is FTerm in the FEDB (dbForEachCellFTerm)
instTerm in dbGet is Term in the FEDB (dbForEachInstTerm)
16
Cadence Confidential
17
Cadence Confidential
rect objType is a list with 4 values like {100.1 0.0 100.3 0.2}
use d for dbu values
use Tcl join if you need to flatten the list {1 2 3 4} to 1 2 3 4
pt and ptList objTypes are similar, with ptList a list of lists of lists
18
Cadence Confidential
19
Cadence Confidential
dbSet
dbSet allows editing of appropriate attribute fields, but
nott pointers
i t
Does not support creation or deletion of objects
Currently very limited: only a few attributes supported
placement status, halo values, gap values
dbget .?h descriptions show (settable) for attributes that can be
changed using
sing dbSet
20
Cadence Confidential
dbSchema
dbSchema provides a way to find the attributes available
for an object type when you dont
don t have the pointer
already
dbSchema allows filtering to simplify output and look for
objects with a common attribute
Syntax: dbSchema [-help] [objNamePattern
[objAttrNamePattern]]
Example: Find out which objects contain object or attributes that
match the *ptn* pattern.
encounter> dbSchema * *ptn*
===================================================
hInst: Hierarchical instance (derived from netlist)
===================================================
ptn: obj(ptn), Pointer to the partition
===============================
head: Root/Head of the database
===============================
ptns: objList(ptn),
p
j
p
List of p
pointers to p
partitions in the design
g
Cadence Confidential
22
Cadence Confidential
23
Cadence Confidential
24
Cadence Confidential
Summary
It would be impossible
p
to p
provide native functionality
y to
suit every need that might arise, so db access
commands are useful in bridging the gap between tool
functionality and whats
what s needed to get chips
implemented
dbGet and dbSet provide a simple, consistent way to
programmatically probe and tweak the database
We welcome your suggestions for improvement to
dbGet and hope you find it useful
25
Cadence Confidential