当前位置:网站首页>使用SystemVerilog门模型描述的组合逻辑
使用SystemVerilog门模型描述的组合逻辑
2022-06-22 05:33:00 【傻童:CPU】
使用SystemVerilog门模型描述的组合逻辑
模块和文件
组合逻辑是无状态的,换言之,输人的变化立即反映在输出的改变上。
SystemVerilog的基本构造单元是模块(module)。
module And2 (input wire x,y,output wire z);
assign z = x & y;
endmodule
模块描述从关键字module开始,接着是模块名和括号中的输入和输出列表。模块以关键字endmodule结束 请注意,在模块的第一句后有分 号“;”,但是在关键字endmodule后面没有分号。
在上述例子中,该模型只有一条声明语句。用关键字 assign来表明所谓的连续赋值 (continuous assignment)语句(这将在后面解释)。x和y 的按位相与得到的值被赋给z。SystemVerilog的算术和逻辑操作符是基于C语言的。
建议读者在组织设计工作中遵循下列指导原则:
- 每个模块都有自己独自的文件。
- 文件名与模块名应该完全一致。
- Verilog和SystemVerilog文件名通常分别用“.v”和“sv”作为其文件名的后缀,而本书中所有的例子都用“.v”作为文件名的后缀。
- 在文件名、文件夹和目录名中不要使用空格,即使操作系统允许这样命名,但是有些 EDA工具还是不能处理带空格的文件名)。
延迟
为了验证时序仿真模型必须包括时序信息。包括时序信息的最简单方法是为每个门建立延迟模型。例如,10ps延迟的与非门可以写成如下形式:
nand #10ps g1(y,a,b);
在上面这个例子中,只有一个延迟参数。在与非门的场
边栏推荐
- Vscode remote connection error: server status check failed - waiting and retrying
- Overview analysis and investment forecast report of semiconductor refrigeration devices in the world and China 2022-2027
- Use and decoupling of the mobile terminal's realm database, and use OC realm safely across threads
- Grabcut analysis
- Development forecast and investment risk outlook report of China's GaAs industry during the 14th Five Year Plan period 2022-2027
- Stockage des données (avancé)
- mysql基础面试题
- Viewing advanced numbers from the perspective of vector space (1) -- a series introduction
- GrabCut分析
- Delete the packaging use of pop-up components
猜你喜欢

总有人问我:独立站该怎么玩?3个案例,你看完就懂了

RGB及sRGB与XYZ坐标转换

Implementation of large file fragment uploading based on webuploader

我不建议你工作太拼命

n个整数的无序数组,找到每个元素后面比它大的第一个数,要求时间复杂度为O(N)

服务器php相关网页开发环境搭建

The first week of wechat applet development: page setup, page Jump and data binding

独立站优化清单丨如何有效提升站内转化率?

Analysis of 43 cases of MATLAB neural network: Chapter 28 Application Research of decision tree classifier - breast cancer diagnosis

C language pointer (Advanced)
随机推荐
Innosetup method for judging that the program has run
Global and Chinese silicon carbide barrier Schottky diode market demand and future prospect report 2022-2027
Analysis on the development status of China's copper aluminum composite bus industry and Research Report on investment opportunities 2022-2027
count registers in C code -- registers has one pattern
机器学习笔记 六:逻辑回归中的多分类问题之数字识别
Air conditioning (daily question 50 in spring)
Global and Chinese carbon conductive filler market demand trend and future prospect report 2022-2027
How wechat applet assigns values to sub components
Hide symbol of dynamic library
以太网UDP帧发包设计
Viewing advanced numbers from the perspective of vector space (1) -- a series introduction
數據的存儲(進階)
Learning method 3 for promotion of large enterprises: chain learning method
想投放Facebook广告却不知从何入手?此文带你深入了解
Implementation of large file fragment uploading based on webuploader
Xshell下载安装(解决评估过期问题)
Research Report on demand and investment opportunities in key areas of global and Chinese strontium tungstate industry 2022-2027
Development prospect forecast and investment strategy analysis report of global and Chinese manganese oxide nano powder industry 2022-2028
参数序列化
Force deletion of namespaces in terminating state