当前位置: 首页 > news >正文

汇鑫网站建设方便wordpress图片处理类

汇鑫网站建设方便,wordpress图片处理类,建设单位网站,合肥公司网站建设价格低1 基本概念 在 SystemVerilog 中,unique if是一种条件判断结构。它用于检查多个互斥的条件,以确保在给定的情况下只有一个条件分支被执行。这有助于提高代码的可读性和可维护性,同时也能帮助发现潜在的逻辑错误,报错原因有以下两个…

1 基本概念

        在 SystemVerilog 中,unique if是一种条件判断结构。它用于检查多个互斥的条件,以确保在给定的情况下只有一个条件分支被执行。这有助于提高代码的可读性和可维护性,同时也能帮助发现潜在的逻辑错误,报错原因有以下两个

        当所有的 “if” 条件都不匹配时且无else语句,会报错。
        当在 “if-else” 条件中发现有不止一个条件匹配时,会报错。

2 语法

unique if (condition1) begin// 执行语句块1
end else if (condition2) begin// 执行语句块2
end else if (condition3) begin// 执行语句块3
end else {// 可选的else语句块,当所有前面条件都不满足时执行
}

3 示例

1 No else block for unique-if(无else,且都不匹配)

module tb;int x = 4;initial begin// This if else if construct is declared to be "unique"// Error is not reported here because there is a "else"// clause in the end which will be triggered when none of// the conditions matchunique if (x == 3)$display ("x is %0d", x);else if (x == 5)$display ("x is %0d", x);else$display ("x is neither 3 nor 5");// When none of the conditions become true and there// is no "else" clause, then an error is reportedunique if (x == 3)$display ("x is %0d", x);else if (x == 5)$display ("x is %0d", x);end
endmodule//------------- simulation log-------------------//
ncsim> run
x is neither 3 nor 5
ncsim: *W,NOCOND: Unique if violation:  Every if clause was false.File: ./testbench.sv, line = 18, pos = 13Scope: tbTime: 0 FS + 1ncsim: *W,RNQUIE: Simulation is complete.

2 Multiple matches in unique-if(匹配多次)

module tb;int x = 4;initial begin// This if else if construct is declared to be "unique"// When multiple if blocks match, then error is reportedunique if (x == 4)$display ("1. x is %0d", x);else if (x == 4)$display ("2. x is %0d", x);else$display ("x is not 4");end
endmodule//--------------- simulation log-----------------//
ncsim> run
1. x is 4
ncsim: *W,MCONDE: Unique if violation:  Multiple true if clauses at {line=8:pos=15 and line=10:pos=13}.File: ./testbench.sv, line = 8, pos = 15Scope: tbTime: 0 FS + 1ncsim: *W,RNQUIE: Simulation is complete.

https://www.chipverify.com/systemverilog/systemverilog-unique-priority-if-ele

http://www.yayakq.cn/news/87907/

相关文章:

  • 深圳市网站建设制作设计品牌学网页设计哪个培训学校好
  • 博罗网站开发国家企业信息公示系统官网平台
  • 增光路网站建设正规seo排名公司
  • 上上海海网网站站建设wordpress整站安装
  • 如何免费建设一个网站个人注册域名怎么申请
  • ico网站建设wordpress屏蔽谷歌字体
  • 福州百度网站快速优化高端网咖电脑配置
  • 凡科网上建设成功的网站1一2万电动汽车
  • 购物手机网站建设注册营业执照网站
  • 我是做网站怎么赚钱山东建设执业师官方网站
  • 哪做网站好什么是网络营销战略
  • 钓鱼网站查询系统成都比较好的装修设计公司
  • 网站正在建设中 公告设计一套vi的报价
  • 专业的网站开发公司电话什么网站可以找人做设计
  • 做网站需要什么cailiao建站行业突破
  • 天津网站建设wangzhii华为用了哪些网络营销方式
  • 物联网平台功能seo网站系统
  • 网站开发项目总结网站建设 7 24
  • 公司网站没备案克隆网站怎么做
  • 需要做网站建设和推广wordpress 自动汉化
  • 互联网项目网站好网站建设公司选择哪家好
  • 医疗电子的网站建设wordpress 缩率图
  • 女装网站建设文献综述网站建设验收合格确认书
  • 江门专业网站制作公司凡科网站插件代码
  • 暂时没有域名怎么做网站留言板网站模板
  • 教育网站制作价格网站站点怎么做
  • 一个空间怎么放多个网站吗网页制作视频教程网
  • 广州网站制作到诺然wordpress win8 主题下载
  • 网站建设前的分析第一小节内容百度爱采购网站
  • 网站设计和美工一样吗招聘网站怎么做线下活动