How to create single instance coverage for interface

Hi,

single instance of the class based coverage is created by using option.per_instance = 0, but how to create the single instance in interface based coverage.

Thank you,
Kruthi

option.per_instance does not control how many instance get constructed; It controls how the coverage calculation from multiple instances results get merged together. If you only create one instance of a covergroup, the option does not matter.

A class can only create one instance of an embedded covergroup (a covergroup defined inside a class). The only way to get multiple instances of an embedded covergroup is constructing multiple instances of the class.

For covergroups defined outside of a class, you can construct as many covergroup instances as you want, it does not matter if the construction comes from a class, module, or interface.