How the coverpoint variable is tracked to calculate the no. of times variable is hit

Hi Forum.,

  • How Coverpoint will keep a track of variable to be covered.i.e.,
    When the covergroup sample function is called ,from that point of time to till the end of the test will the coverpoint variable be tracked ,or only at the point of time when sample() method is called it works.
  • Because for any coverpoint variable if it is said it as a hit of 9 or 10 means, that varaible as to be exercised or used 9 or 10 times. But when we call sample() method only once, how it will know the coverpoint variable is hitted 9 or 10 times.

Any suggestion are appreciated.
Thanks in Advance.

In reply to Yash_wanth12345:

A “hit” gets counted only when calling sample() or triggering sampling event AND the sampled value matches one of the bin values. It is discrete sampling, not continuous tracking.