当前位置:   article > 正文

modelsim独立仿真与联合仿真生成覆盖率流程(随笔)_modelsim代码覆盖率

modelsim代码覆盖率

modelsim 覆盖率统计

无脚本
生成modelsim工程文件,代码编译成功
在这里插入图片描述
在这里插入图片描述
全选代码按这个设置
在这里插入图片描述
到library界面,打开work,选择写好的TB文件,选择仿真和覆盖率统计
在这里插入图片描述
进入仿真界面,点击左上角向下三角,我一般选择这几项,可随意选择。
在这里插入图片描述
在没有运行之前,起码代码覆盖率要显示0%,不显示说明还有问题。

脚本运行

下面展示的是我通过ISE与modelsim联合仿真时生成的.fdo脚本文件 内联代码片

######################################################################
##
## Filename: TB_TOP.fdo
## Created on: Wed Jun 08 22:30:21 中国标准时间 2022
##
##  Auto generated by Project Navigator for Behavioral Simulation
##
##  ---------------------DO NOT EDIT THIS FILE-------------------------
##  You may want to add additional commands to control the simulation
##  in the user specific do file (<module>.udo) which is automatically
##  generated in the project directory and will not be removed on
##  subsequent simulation flows run from Project Navigator.
##  ---------------------DO NOT EDIT THIS FILE-------------------------
##
######################################################################
#
# Create work library
#
vlib work
#
# Compile sources
#
vcom -explicit  -93 "ipcore_dir/clk_ip.vhd"
vcom -explicit  -93 "ipcore_dir/gtwizard_v2_7_gt.vhd"
vcom -explicit  -93 "ipcore_dir/gtwizard_v2_7/example_design/gtwizard_v2_7_sync_block.vhd"
vcom -explicit  -93 "ipcore_dir/gtwizard_v2_7/example_design/gtwizard_v2_7_tx_startup_fsm.vhd"
vcom -explicit  -93 "ipcore_dir/gtwizard_v2_7/example_design/gtwizard_v2_7_rx_startup_fsm.vhd"
vcom -explicit  -93 "ipcore_dir/gtwizard_v2_7.vhd"
vcom -explicit  -93 "ipcore_dir/gtwizard_v2_7/example_design/gtwizard_v2_7_init.vhd"
vcom -explicit  -93 "ipcore_dir/gtwizard_v2_7/example_design/gtwizard_v2_7_gt_usrclk_source.vhd"
vcom -explicit  -93 "ipcore_dir/gtwizard_v2_7/example_design/gtwizard_v2_7_gt_frame_gen.vhd"
vcom -explicit  -93 "ipcore_dir/gtwizard_v2_7/example_design/gtwizard_v2_7_gt_frame_check.vhd"
vcom -explicit  -93 "ipcore_dir/gtwizard_v2_7/example_design/gtwizard_v2_7_recclk_monitor.vhd"
vcom -explicit  -93 "ipcore_dir/gtwizard_v2_7/example_design/gtwizard_v2_7_exdes.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip2_gt.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip2/example_design/gtx_ip2_sync_block.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip2/example_design/gtx_ip2_tx_startup_fsm.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip2/example_design/gtx_ip2_rx_startup_fsm.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip2.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip2/example_design/gtx_ip2_init.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip2/example_design/gtx_ip2_gt_usrclk_source.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip2/example_design/gtx_ip2_gt_frame_gen.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip2/example_design/gtx_ip2_gt_frame_check.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip2/example_design/gtx_ip2_recclk_monitor.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip2/example_design/gtx_ip2_exdes.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip4_gt.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip4/example_design/gtx_ip4_sync_block.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip4/example_design/gtx_ip4_tx_startup_fsm.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip4/example_design/gtx_ip4_rx_startup_fsm.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip4.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip4/example_design/gtx_ip4_init.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip4/example_design/gtx_ip4_gt_usrclk_source.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip4/example_design/gtx_ip4_gt_frame_gen.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip4/example_design/gtx_ip4_gt_frame_check.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip4/example_design/gtx_ip4_recclk_monitor.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip4/example_design/gtx_ip4_exdes.vhd"
vcom -explicit  -93 "gtx_tx_fifo.vhd"
vcom -explicit  -93 "gtx_rx_fifo.vhd"
vcom -explicit  -93 "icon_ip2.vhd"
vcom -explicit  -93 "ila_ip.vhd"
vcom -explicit  -93 "gtx_ip4_exdes/gtx_ip4_sync_block.vhd"
vcom -explicit  -93 "gtx_ip2_exdes/gtx_ip2_sync_block.vhd"
vcom -explicit  -93 "gtx_ip1_exdes/gtwizard_v2_7_sync_block.vhd"
vcom -explicit  -93 "gtx_ip4_exdes/gtx_ip4_tx_startup_fsm.vhd"
vcom -explicit  -93 "gtx_ip4_exdes/gtx_ip4_rx_startup_fsm.vhd"
vcom -explicit  -93 "gtx_ip2_exdes/gtx_ip2_tx_startup_fsm.vhd"
vcom -explicit  -93 "gtx_ip2_exdes/gtx_ip2_rx_startup_fsm.vhd"
vcom -explicit  -93 "gtx_ip1_exdes/gtwizard_v2_7_tx_startup_fsm.vhd"
vcom -explicit  -93 "gtx_ip1_exdes/gtwizard_v2_7_rx_startup_fsm.vhd"
vcom -explicit  -93 "uart_rx.vhd"
vcom -explicit  -93 "navi_tx_fifo.vhd"
vcom -explicit  -93 "gtx_ip4_exdes/gtx_ip4_init.vhd"
vcom -explicit  -93 "gtx_ip4_exdes/gtx_ip4_gt_usrclk_source.vhd"
vcom -explicit  -93 "gtx_ip2_exdes/gtx_ip2_init.vhd"
vcom -explicit  -93 "gtx_ip2_exdes/gtx_ip2_gt_usrclk_source.vhd"
vcom -explicit  -93 "gtx_ip1_exdes/gtwizard_v2_7_init.vhd"
vcom -explicit  -93 "gtx_ip1_exdes/gtwizard_v2_7_gt_usrclk_source.vhd"
vcom -cover bcest -explicit  -93 "UART_TX96.vhd"
vcom -cover bcest -explicit  -93 "UART_RX80.vhd"
vcom -cover bcest -explicit  -93 "SRIO_send.vhd"
vcom -cover bcest -explicit  -93 "SRIO_recv.vhd"
vcom -explicit  -93 "gtx_ip4_exdes.vhd"
vcom -explicit  -93 "gtx_ip2_exdes.vhd"
vcom -explicit  -93 "gtx_ip1_exdes.vhd"
vcom -explicit  -93 "FB3_GT0_send.vhd"
vcom -explicit  -93 "FB3_GT0_recv.vhd"
vcom -explicit  -93 "FB2_GT1_send.vhd"
vcom -explicit  -93 "FB2_GT1_recv.vhd"
vcom -explicit  -93 "FB2_GT0_send .vhd"
vcom -explicit  -93 "FB2_GT0_recv.vhd"
vcom -explicit  -93 "FB1_GT1_send.vhd"
vcom -explicit  -93 "FB1_GT1_recv.vhd"
vcom -explicit  -93 "FB1_GT0_send.vhd"
vcom -explicit  -93 "FB1_GT0_recv.vhd"
vcom -cover bcest -explicit  -93 "jiaohuan_fpga.vhd"
vlog -cover bcest "TB_TOP.v"
vcom -explicit  -93 "ipcore_dir/gtx_ip3/example_design/gtx_ip3_gt_usrclk_source.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip3/example_design/gtx_ip3_init.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip3/example_design/gtx_ip3_sync_block.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip3/example_design/gtx_ip3_tx_startup_fsm.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip3/example_design/gtx_ip3_rx_startup_fsm.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip3/example_design/gtx_ip3_recclk_monitor.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip3/example_design/gtx_ip3_gt_frame_gen.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip3/example_design/gtx_ip3_gt_frame_check.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip3_gt.vhd"
vcom -explicit  -93 "ipcore_dir/gtx_ip3/example_design/gtx_ip3_exdes.vhd"
vlog -cover bcest "D:/ISE/14.7/ISE_DS/ISE//verilog/src/glbl.v"
#
# Call vsim to invoke simulator
#
vsim -coverage  -voptargs="+acc" -t 1ps  -L xilinxcorelib_ver -L unisims_ver -L unimacro_ver -L secureip -lib work work.TB_TOP glbl

#
# Source the wave do file
#
do {TB_TOP_wave.fdo}
#
# Set the window types
#
view wave
view structure
view signals
#
# Source the user do file
#
do {wave.do}
#
# Run simulation for this time
#
run 0
#
# End
#

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52
  • 53
  • 54
  • 55
  • 56
  • 57
  • 58
  • 59
  • 60
  • 61
  • 62
  • 63
  • 64
  • 65
  • 66
  • 67
  • 68
  • 69
  • 70
  • 71
  • 72
  • 73
  • 74
  • 75
  • 76
  • 77
  • 78
  • 79
  • 80
  • 81
  • 82
  • 83
  • 84
  • 85
  • 86
  • 87
  • 88
  • 89
  • 90
  • 91
  • 92
  • 93
  • 94
  • 95
  • 96
  • 97
  • 98
  • 99
  • 100
  • 101
  • 102
  • 103
  • 104
  • 105
  • 106
  • 107
  • 108
  • 109
  • 110
  • 111
  • 112
  • 113
  • 114
  • 115
  • 116
  • 117
  • 118
  • 119
  • 120
  • 121
  • 122
  • 123
  • 124
  • 125
  • 126
  • 127
  • 128
  • 129
  • 130
  • 131
  • 132
  • 133
  • 134

在这里插入图片描述
这里引用我之前找到的资料照片还是比较全的,补充一点,.vhd文件在脚本中以vcom开头与.v文件不同注意甄别,但是操作一致。

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/从前慢现在也慢/article/detail/709099
推荐阅读
相关标签
  

闽ICP备14008679号