当前位置:网站首页>Xilinx Vivado set *.svh as SystemVerilog Header
Xilinx Vivado set *.svh as SystemVerilog Header
2022-07-02 11:21:00 【Ayka】
Xilinx Vivado does not support setting the file type of a file as SystemVerilog Header till now (version 2021.2.1). This article assumes using "Vivado" Syntax Checking for Xilinx Vivado Text Editor.
Import *.svh files to Design Sources, where their hierarchy layer is "Non-module Files". In "Sources" sub-window, right-click the .svh files,and click "Set Global Include". After that, *.svh files are appeared in "Global Include" hierarchy layer:

The default file type of these *.svh files is "Verilog Header", so if these *.svh files contain syntaxes that are not Verilog-only, then the syntax checking of Vivado Text Editor will show syntax errors. However, if you set their file type as "SystemVerilog", then the syntax checking will throw no errors for design sources, but throw syntax errors for simulation sources still. Nevertheless, they can both do successful simulations. Obviously, it is a bug of Vivado's syntax checking. If you really do not like the wrong buggy syntax checking, you can try switching file types and doing simulations, then the bug may disappear.
If you add
`include "sys_defs.svh"at the beginning of the simulation sources and the file type of these *.svh files is "Verilog Header", the syntax checking will throw the warning "Warning: cannot open include file 'sys_defs.svh' ", and syntax errors same as the case without the include statement. If the file type of these *.svh files is "SystemVerilog", then the syntax errors are the same as the case that the file type of these *.svh files is "Verilog Header", but the simulation will fail:
ERROR: [VRFC 10-3195] cannot open include file 'sys_defs.svh' [F:/Documents/GitHub/ECE4700J_SU2022/Lab4/project-v-open-beta-For-ECE4700J/optimization/testbench/mem.sv:1]
INFO: [VRFC 10-311] analyzing module mem
ERROR: [VRFC 10-2865] module 'mem' ignored due to previous errors [F:/Documents/GitHub/ECE4700J_SU2022/Lab4/project-v-open-beta-For-ECE4700J/optimization/testbench/mem.sv:18]
and
ERROR: [USF-XSim-62] 'compile' step failed with error(s). Please check the Tcl console output or 'F:/Documents/GitHub/ECE4700J_SU2022/Lab4/lab_4/lab_4.sim/sim_1/behav/xsim/xvlog.log' file for more information.
ERROR: [Vivado 12-4473] Detected error while running simulation. Please correct the issue and retry this operation.
launch_simulation: Time (s): cpu = 00:00:01 ; elapsed = 00:00:07 . Memory (MB): peak = 1551.020 ; gain = 0.000
ERROR: [Common 17-39] 'launch_simulation' failed due to earlier errors.
so do not do that. In brief, do not use any "include" statements.
边栏推荐
- NLA natural language analysis realizes zero threshold of data analysis
- Uniapp automated test learning
- 万物生长大会在杭召开,当贝入选2022中国未来独角兽TOP100榜单
- MQ教程 | Exchange(交换机)
- Fabric.js 自由绘制椭圆
- 【空间&单细胞组学】第1期:单细胞结合空间转录组研究PDAC肿瘤微环境
- 没有从远程服务器‘‘映射到本地用户‘(null)/sa‘的远程用户‘sa‘及服务主密码解密错误的解决办法
- STM32标准固件库函数名记忆(二)
- Design and implementation of car query system based on php+mysql
- Generally speaking, if the error of inconsistent tab and space occurs frequently
猜你喜欢

Daily learning 2

关于Flink框架窗口(window)函数最全解析

obsidian安装第三方插件——无法加载插件

复用和分用

A white hole formed by antineutrons produced by particle accelerators

YOLOv3&YOLOv5输出结果说明

Systemserver process

Yolov3 & yolov5 output result description

C crystal report printing

《可供方案开发》口算训练机/数学宝/儿童口算宝/智能数学宝 LCD液晶显示驱动IC-VK1622(LQFP64封装),原厂技术支持
随机推荐
Using computed in uni app solves the abnormal display of data () value in tab switching
Solving the longest subsequence with linear DP -- three questions
The evolution process of the correct implementation principle of redis distributed lock and the summary of redison's actual combat
Golang 快速生成数据库表的 model 和 queryset
Fabric.js 缩放画布
< schematic diagram of oral arithmetic exercise machine program development> oral arithmetic exercise machine / oral arithmetic treasure / children's math treasure / children's calculator LCD LCD driv
Design and implementation of car query system based on php+mysql
NLA natural language analysis realizes zero threshold of data analysis
uniapp自动化测试学习
Methods of software testing
STM32标准固件库函数名(一)
Pycharm连接远程服务器
Fabric.js 自由绘制圆形
测试框架TestNG的使用(二):testNG xml的使用
Yyds dry goods inventory software encryption lock function
Fabric. JS zoom canvas
Data consistency between redis and database
数据库连接池和数据源
字符串匹配问题
NLA自然语言分析实现数据分析零门槛