Changing clocking block clock polarity on the fly
问题 I am creating UVM VIP which is able to switch its clock polarity. Clocking block is used in the interface. For example, a monitor should sample the data using posedge or negedge of incoming clock depending on UVM configuration - and this polarity change can happen on the fly. This can be implemented as follows: // In the interface, two clocking blocks are defined // one for posedge (passive_cb), one for negedge (passive_cbn). task wait_clock_event(); if (cfg.pol == 0) @vif.passive_cb; else