Clock edge is not getting detected inside forever loop

In reply to rakesh2learn:

It is possible that the clock ‘hclk’ is not getting generated and is not connected to top level clock.

  • Add a check to see if you are getting interface pointer from configuration database,
if(!uvm_config_db#(virtual ahb_if)::get(this,"","phy_intf_var",vif))
  `uvm_fatal("AHB/MON", "Cannot get virtual interface.");