object base基类分析

uvm_object,是所有uvm data和hierarchical class的基类,实现了copy,compare,print,record之类的函数

      扩展类中必须实现create和get_type_name函数,get_type函数。

uvm_object从uvm_void中扩展出来,uvm_void是一个virtual class,不包含任何其他东西。

声明了一个static类型的变量 uvm_status_container    __m_uvm_status_container;

new函数:inst_count表示目前tb例化过的class个数,m_leaf_name,表示该class的name;

       inst_count是一个static类型的变量

      

clone函数:默认的实现方式,先create在copy;uvm_component不是使用create函数,所以也不支持clone;

       

convert2string函数:

print/sprint函数。print函数会调用sprint函数,

    fwrite,将字符串打包到一个指针文件中,也就是mcd中。

      

    sprint将需要print的信息打到一个string中,sprint函数会在调print_object之前,调用do_print;

      

      

copy函数:do_copy函数默认为空。

record函数:

compare函数:

pack函数:

set_local_*函数:

原文地址:https://www.cnblogs.com/-9-8/p/7567381.html