IUS tcl cmd

Incisive simulator中的command-line language基于TCL。

Ncsim> command [-modifier] [-options] [arguments]

其中command必须是小写的。路径可以用”/” ”.” ”:”来作为分隔符。(verilog顶层不用加,VHDL顶层加:)

Uvm中的顶层:uvm_pkg::uvm_top.top_levels[xx].leaf_name

其中通识符的使用:

*表示任意字符任意长度的替换;

?表示任意的单个字符;

在其中执行UNIX cmd:

直接执行shell cmd或者exec + file或者直接shell file

其他tcl支持的foreach以及ifelse等控制也可以使用。

1)       alias [-set|-unset] {alias_name} {defination}

           alias –set h history

2)       analog在mixed-signal simualtion中控制analog solver

3)       assertion 控制仿真中的SVA

           assertion [-off|-on|-logging|-summary|-counter|-simstop] {-all|-depth|-severity}

4)       attribute 使能VHDL中某些信号的一些attribute,方便之后使用value来显示。

5)       call 调用事先定好的verilog PLI task。

6)       check 只能用在检查VHDL中的bus信号上,检查bus contention和bus float condition

7)       constraint 对一个class中的randomize call,新加一个SV的randomization。

           stop  –randomize 在randomize的系统调用中,设置breakpoint。

           Deposit  –constraint_mode 使能或者disable某个constraint。

           Deposit  -rand_mode 使能或者disable某个随机variable。

           Run  –rand_solve 再执行randomize()一次。

8)       coverage  –code/fsm/toggle/ -reset 复位已经收集到的coverage。

                         —setup [-workdir <workdir>] [-design <design>]

                                     [-test <test>] [-dut <dut_instance>]

         -functional –select/-deselect 选择coverage point。

         -off 关闭coverage storing, -analyze 打开分析工具。

9)  database 与probe命令同时使用,控制SHM/VCD/EVCD的database。

            同时在TB中必须是有相应database的create。

            SHM--$recordvars,$recordfile/VCD---$dumpvars,$dumpfile。

1)       deposit 变量赋初值,之后随着driver驱动。

2)       describe 显示仿真中的一些枚举以及class,param和power信息。

        -localparam/-param/-power

3)  driver   显示当前的某个变量的驱动

           -active/

4)  dumpsaif 仿真中产生一个SAIF的文件。

           -scope/-depth/-end

5)  dumptcf  仿真中产生一个TCF(Toggle Count Format)文件

6)  exit 退出仿真,类似的还有finish和exit命令。

7)  find命令,查找。

     -blocks/-instances/-internals[-signals|-variables|-wires|-registers]

8)  force/release命令

9)  heap命令显示heap中的object,-type可以显示string/event/covergroup/associative array/quaue/dynamic array/Class/mailbox/semaphore

    类似的还有stack

1)  history命令。显示old command

2)  input和source命令,执行script

3)  logfile保存Tcl command的输出到一个特定的log文件中。

         -append/-overwrite

4)  loopvar显示verilog或者vhdl的loop variable

5)  power命令显示一些power信息

6)  scope显示当前的debug scope

7)  simvision直接打开simvision gui来调试

8)  value显示某个hierarchy下的信号的值

9)  strobe在某个时间点或者信号变化时,打印出log信息。

1)  stop -condition {}设置断点

1)  tcheck 关闭或打开,timing check message和notifier updates 对于一个给定的verilog instance

        tcheck instance_path  -off/-on 

2)  初始化memory:
        memory -load ram_hier -file load.hex -start 0
        memory -load ram_hier -defval 0
        memory -dump ram_hier -file dump.hex
原文地址:https://www.cnblogs.com/-9-8/p/6006889.html