数字IC设计学习笔记
TCL在EDA工具中的扩展与应用
1. TCL的应用
2. 综合软件中TCL常见指令
3. 数据类型object与其属性attibute
1. TCL的应用
TCL: Tool Command Language 工具命令语言
TCL脚本基于命令:
- 内建命令
- 应用命令:支持C,C++扩展
- 支持用户自定义的
Synopsys TCL:强大,灵活,简单易用
2. 综合软件中TCL常见指令
逻辑综合,设计有两种表达方式:
- 结构化的
- 代码的
DC常用指令
- Get_ports portsname:返回设计中对应的ports object
- Get_cells cellsname:返回design中对应的cell的instance name object
- Get_nets netsname: 返回design中所有net object
- Get_pins pinsname: 返回design中pin的object
3. 数据类型object与其属性attibute
Cell object
- 属性 ref_name : 用来保存其map到的reference cell名称
- Shell> get_attribute [get_cells –h U3] ref_name {INV}
Pin object:
- 属性 owner_net : 用来保存与之相连的net的名称
- Shell> get_attribute [get_pins U2/A] owner_net {BUS0}
Port object:
-
属性 direction : 用来保存port 的方向(in, out)
-
Shell> get_attribute [get_ports A] direction {in}
-
Shell> get_attribute [get_ports OUT[1]] direction {out}
Net object:
- 属性 full_name : 用来保存net的名称
- Shell> get_attribute [get_nets INV0] full_name {INV0}
- Shell> get_object_name [get_nets INV0] {INV0}
- *Shell> get_attribute INV0 full_name Error: No attribute found
- get_* -f :
-f 这个option可以用来过滤属性,以得到我们想要的object
- get_* [object]-of:
-of 这个option可以用来得到与你指定object相连接的object
[参考资料]
- 邸志雄老师的课件
- 《Using Tcl with SynopsysTools》
【注】:个人学习笔记,如有错误,望不吝赐教,这厢有礼了~~~