¿ªÔÆÌåÓý

ctrl + shift + ? for shortcuts
© 2025 Groups.io

Re: Testbenches


 

I have written some helper modules for testbenches, depending on what you're doing they may also be helpful for you.
?
1) A "scoreboard" where you can put reference data as well as "dut" data. The module will then compare and can provide some stats at the end.
2) Randomizer modules for generating (input) data, similar to the Randomizable libary which Julie mentioned above. They have two advantages: You can use it with a "user-provided" seed, which allows to replicate specific test runs which failed earlier. And they work with enums and tagged unions (the Randomizable library can produce invalid values there, e.g. for enum with 3 values with bit represenation 00,01,10 it also generates 11; my implementation prevents this, however the distribution is not uniform in those cases).
?
You can find them here in our small library (or to be more precise my fork of it, as it is not yet merged):
?
I also have some documentation here:
?
Johannes

Join [email protected] to automatically receive all group messages.