Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Settinng environment using modelsim for systemverilog

Status
Not open for further replies.

gautamvsharma

Junior Member level 2
Joined
Jul 11, 2010
Messages
24
Helped
4
Reputation
8
Reaction score
3
Trophy points
1,283
Location
Bangalore
Activity points
1,457
Hi,

I have some problem that i need to share and expecting some master reply to solve my problem,

I have RTL design written in VHDL, i did functional simulation using VHDL & Verilog testbence, as verilog have more & effective simulation constructs.

Now i need to write testcases using SYstem verilog, and i need to build environment using modelsim v6.4.

So anyone can help me to build environment for RTL verification with Systemverilog & Modelsim?

Any detailed help is highly appreciated.......

Thanks in advance...
 

for modelsim you only add "-sv" option ,then you can do simulation for SV!
 

Thanks dear for your response,

can you please tell me, how do i create .SV for my VHLD/VERILOG design file, and how do i simulate it in modelsim environment.?

Thanks in advance.
 

Hi,

First, you create a Verilog wrapper for your blocks/ top-level block that you want to verify. Then you instantiate this wrapper in the SV testbench file and proceed by adding test cases etc..
you must compile the VHDL RTL first, then the verilog files followed by the SV files and then simulate the top-level testbench passing the testname in the vsim command like:

vsim +incdir +.... -f <file_name with compile list> -sv +TESTNAME = <test name> ...etc
 

1) add modelsim // add the appropriate version
2) setenv MODELSIM modelsim.ini// modelsim.ini contains all the initial settings and must be in the directory
3) vlog *.vp // compiles all verilog files
4) vlog -sv -mfcu *.sv // compiles all systems verilog files
 

Thanks vlsi_whiz and sam33r, both suggestions were stand valuable for me,

I have RTL written on VHDL, which is synthesizable.
I need to do randomize coverage driven verification in SV, I am using MODELSIM 6.4..

please let me know, if i am wrong in some steps,

first, I will creat, verilog wrapper instantiation model, then create new .sv file using Modelsim.
secondly, I will instantiate newly generated wrapper with .SV Testbench file(re-instantiation of core RTL via verilog wrapper model)
thirdly, I will write different testcases in it..

If i am correct by above steps, I can simulate my design functionally, and can see the waveforms.

Is there any environment variable or any background switch is required to use all component of systemverilog in modelsim?

Thanks,
Gautam
 

if you only need system verilog code to write test case , you can add "sv" option when run simulation!
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top