2013-11-02 97 views
-1

我正在为我的VHDL IP写一个systemverilog封面组。我的计划是编写一个单独的SV代码,我假设我可以访问我的VHDL IP的内部信号。之后,我只需要做一个绑定,以便SV代码段被模拟器自动实例化为VHDL。如果我错了,请纠正我。我以前从未使用过绑定。绑定systemverilog封面组与vhdl模块

之前,我开始,我是想看看如何绑定工作,并写了一个小程序来测试它。这是...

test_bind.sv

module test_bind(input clk, input enable); 
    initial @(posedge clk) $display("binding worked!!"); 
endmodule 
bind my_vhdl_module test_bind instance_test_bind(clk, enable); 

现在,当我尝试编译它,我得到以下错误:

Following verilog source has syntax error : 
    "test_bind.sv", 5: token is 'test_bind' 
    bind my_vhdl_module test_bind instance_test_bind(clk, enable); 
           ^

my_vhdl_module是简单的VHDL代码的src。我也尝试了与my_vhdl_module的一个非常简单的verilg相同,但得到相同的错误。我觉得它很愚蠢,因为它看起来像一个简单的错误,但我还没弄明白。对此的任何评论将非常有帮助。

+0

这里有一篇介绍使用'bind'的论文:http://www.sunburst-design.com/papers/CummingsSNUG2009SJ_SVA_Bind。 pdf – toolic

+0

你确定你的模拟器支持这种语法吗?联系供应商。 – toolic

回答