多年来我一直在与verilog合作,但最近我用verilog测试了一些东西。在ncvlog编译期间,我有一个错误,我无法找到原因。以下是代码(尚未完成)。
`include "default.v"
module conv (
input clr,
input clk,
input start_conv,
output integer raddr,
output integer waddr,
input real data_in,
output real data_out
);
parameter NUM_CONV = `DEF_NUM_CONV;
genvar i;
generate
for (i=0; i<NUM_CONV; i=i+1) begin : uconv
unit_conv inst() (
.clr (clr),
.clk (clk),
.start (start_conv),
.rreq (rreq[i]),
.raddr (raddr[i]),
.rdata (rdata[i]),
.wreq (wreq[i]),
.waddr (waddr[i]),
.wdata (wdata[i])
);
end
endgenerate
endmodule
我得到的错误如下:
ckim@stph45:~/Neuro/convhw] ncvlog -sv conv.v
ncvlog: 12.20-s008: (c) Copyright 1995-2013 Cadence Design Systems, Inc.
unit_conv inst() (
|
ncvlog: *E,EXPSMC (conv.v,19|17): expecting a semicolon (';') [12.1.2][7.1(IEEE)].
生成的实例的端口映射语法是否错误?根据{{3}},它似乎是正确的......顺便说一句,我使用ncvlog -SV conv.v
编译。
答案 0 :(得分:0)
请考虑以下事项:
unit_conv inst (
.clr (clr),
.clk (clk),
.start (start_conv),
.rreq (rreq[i]),
.raddr (raddr[i]),
.rdata (rdata[i]),
.wreq (wreq[i]),
.waddr (waddr[i]),
.wdata (wdata[i])
);