仿真时testbench风格导致的竞争现象
近期需要用到一段移位寄存器的程序,却在行为仿真时出现问题,代码如下(一个4位移位寄存器):modulesr4(inputclk,inputen,inputd,outputregq);reg[3:0]q_temp;always@(posedgeclk)beginif(en)beginq_temp[3:0]<={q_temp[2:0],d};q<=0;endelse
发表于 12/1/2014 9:12:13 PM
阅读(2334)
