I am getting an error regarding interfaces has not defined in top

So, I’m working on RISCV verification using UVM and as a part of that my TB contains 4 agents namely data,instruction,interrupt and reset. For these 4 agents i created 4 interfaces and also instantiated them in the top module. But when i run the code i get the error as interface_name not defined in the top module for the instance.

My top module:


My interfaces:


interface 4

Please solve my issue

Do not post images of your code as they can’t be used to attempt to compile/debug. Instead, you should include the code as part of your post using the appropriate code tags. Better yet, put your code on EDA Playground and provide a link.

You don’t show how you compile your code. Do you compile all files to the same library? Or separate libraries? Are there any syntax errors while compiling?

No, there are no syntax errors while compilation. And i compile them using Make file by including all the files in a package.

Packages are for classes only. Interfaces and modules can’t be part of a package and you will get a compilation error.

You will need to refer to your tool documentation or contact your vendor support team for additional assistance on how to compile your code correctly.

Yes, I didn’t include any interface or module inside the package only files with classes are added. And the tool im using is Questasim

This Siemens sponsored forum is not for tool related issues.

You will need to refer to your tool documentation or contact your vendor support team for additional assistance on how to compile your code correctly.