In reply to dave_59:
First thanks to for your answer.
I am trying to add a light bus that will replace an existing VIP, the interface of the VIP doesn’t give the clock of the interface as input but assign as a wire, in order to avoid ifdef I want to connect the clock of the light bus same.
**So want I need to know if there is any difference between both below examples.
**
Example 1, clk is wire:
Declare the interface:
light_bus_if bus_if();
assign the clk:
bus_if.clk = `TOP.clk;
in the interface:
wire clk;
…
clocking cb @(posedge clk);
Example 2, clk is input:
Declare the interface and give the clock :
light_bus_if bus_if(.clk(`TOP.clk));
in the interface:
interface light_bus_if (input bit clk)
…
clocking cb @(posedge clk);
Thanks