1.将某个component 置于新的domain中,B如下:

UVM:5.3.2 多domain 的例子_递归

1)新建一个domain 并例化。在connect_phase 中通过set_domain 将B 加入到此domain中:原型:

UVM:5.3.2 多domain 的例子_递归_02

2)第二个参数表示是否递归,1表示递归。

3)例化一般在build_phase 完成,所以一般在connect_phase 中调用set_domain。


2:A:

UVM:5.3.2 多domain 的例子_递归_03


3:base_test:

UVM:5.3.2 多domain 的例子_递归_04


4:结果:

UVM:5.3.2 多domain 的例子_递归_05

A 和B 的run-time phase完全异步了。