Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > VHDL > Use of generics at top level of testbench

Thread Tools

Use of generics at top level of testbench

gizmo gizmo is offline
Junior Member
Join Date: Dec 2008
Posts: 1
hi all,
I have been having a look around and although there are a few posts concerning this I still havent found a real answer. Could someone please give me some help or point me in the right direction?

I am trying to perfrom conditional compilation using a generic to control which components of my testbench are included on a testcase by testcase basis.

Basically i am using configurations to setup my testbench for testcases and would like to be able to set a generic to control which components are included. I am planning to use generate statements within an 'if' to control the generation of componants (the reason is to reduce simulation times for quick checks and then release this for over night runs).

I have used generics to pass values to components within my testbench but am unsure how to do this at the top level so any help would be much appreciated.

If it helps heres a sample of one of my configurations

configuration 1 of testbenchtop is
for structure

for inst : tb_comp_1
use entity tb_lib.tb_comp_1(rtl)
generic map(...);
end for;

for inst_dut: dut
use entity work.dut(rtl)
generic map (..);
end for;
end for;
end 1;

any help would be much appreciated, thanks in advance
Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to force an internal wire which is deep inside DUT hierachy attop level testbench using VHDL design? One Cent VHDL 7 09-10-2012 10:53 PM
question regarding passing generics in testbench madmax VHDL 1 10-04-2008 11:31 PM
c is a low-level language or neither low level nor high level language pabbu C Programming 8 11-07-2005 03:05 PM
Change GENERICS at top level for synthess Andy Luotto VHDL 2 02-05-2005 04:58 PM
Changing generics in top-level module Martin Thompson VHDL 5 06-08-2004 11:47 AM