[請益] NC-Verilog的indexed part-select問題

看板Electronics作者 (AnRedR)時間12年前 (2013/05/27 22:06), 編輯推噓0(001)
留言1則, 1人參與, 最新討論串1/1
以下是我把實際遇到的問題簡化後的樣子 module test; reg [0:0] index = 0; reg [0:-1] vector = 0; initial begin #1; $display("%b", vector[index[0]+:1]); end endmodule 用NC-Verilog(版本11.10-s072)模擬後顯示為x不是0 但是用Icarus Verilog模擬出來結果卻是0 想請問版上高手是否indexed part-select這樣使用是behavior undefined或 implementation dependent?或者這是bug? 若把code裡vector的range改成[0:0]或者把index[0]的bit select去掉(即index) 則NC-Verilog模擬出來是變成0了 之前也因為類似的問題debug很久.. 感謝 -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 220.132.214.119

05/27 23:00, , 1F
ncverilog 08.10-p002這個版本似乎就沒這個問題
05/27 23:00, 1F
※ 編輯: AnRedR 來自: 118.170.10.180 (05/27 23:01)
文章代碼(AID): #1HesXMjh (Electronics)