chenyong Posted January 4, 2012 Report Share Posted January 4, 2012 Hi, I found some code with method/variant "m_parent" in uvm-1.1 example of ubus. I can't find this m_parent definition in the code and can't find related infomation in the class reference. Can anybody give me some help? thanks. Quote Link to comment Share on other sites More sharing options...
Roman Posted February 7, 2012 Report Share Posted February 7, 2012 Hi There, As I understand. Based on the layering hierarchy graph of ubus example, Each instance is a node connected to others to form the graph. Hierarchy is overlaid with m_parent. The m_parent in the ubus_master_monitor points to ubus_master_agent instance in the ubus_env. Hope this help you~ Quote Link to comment Share on other sites More sharing options...
chenyong Posted February 7, 2012 Author Report Share Posted February 7, 2012 Hi There, As I understand. Based on the layering hierarchy graph of ubus example, Each instance is a node connected to others to form the graph. Hierarchy is overlaid with m_parent. The m_parent in the ubus_master_monitor points to ubus_master_agent instance in the ubus_env. Hope this help you~ Hi Roman, thanks for your reply. 1) does this mean if I see m_parent in monitor, then I know it points to env? 2) does this mean m_parent is a "default defintion" in UVM? thanks Quote Link to comment Share on other sites More sharing options...
Roman Posted February 7, 2012 Report Share Posted February 7, 2012 for #1: m_parent is a build-in pointer to the parent component for #2: I think m_parent is a build-in in UVM Quote Link to comment Share on other sites More sharing options...
chenyong Posted February 7, 2012 Author Report Share Posted February 7, 2012 thank you very much Quote Link to comment Share on other sites More sharing options...
janick Posted February 7, 2012 Report Share Posted February 7, 2012 Avoid using any undocumented variable or method, especially if prefixed with "m_". Since SystemVerilog does not support friend classes, they are public for implementation reasons. They are not part of the standard and are subject to removal/renaming/modification. Use uvm_component::get_parent(). Quote Link to comment Share on other sites More sharing options...
Roman Posted February 7, 2012 Report Share Posted February 7, 2012 Agree! m_parent occurs in example of UVM pkg, it will mislead guys who may study UVM based on ubus example. I think m_parent should be removed from example of UVM pkg. Quote Link to comment Share on other sites More sharing options...
chenyong Posted February 8, 2012 Author Report Share Posted February 8, 2012 thanks for this information. Is there any other "code" which is not supported by standard but appear in the example? Quote Link to comment Share on other sites More sharing options...
uwes Posted February 9, 2012 Report Share Posted February 9, 2012 hi, in case the examples use internal capabilities it should be considered a bug and will be removed in subsequent releases. /uwe Quote Link to comment Share on other sites More sharing options...
Roman Posted February 13, 2012 Report Share Posted February 13, 2012 thanks for this information. Is there any other "code" which is not supported by standard but appear in the example? Hi, In the ubus example: assign_vif function is used. But this approach is not recommended because of lack of reuse when hierarchy is changing from project to project. I recommend to use the uvm_config_db utility to transmit the vif or cfg obj crossing the hierarchy. Quote Link to comment Share on other sites More sharing options...
chenyong Posted February 14, 2012 Author Report Share Posted February 14, 2012 HI, I guess this is true. In UVM-1.1, I can't find assign_vif but uvm_config_db. It is said uvm-1.2 will come soon, don't know what will be changed at that time. Quote Link to comment Share on other sites More sharing options...
Roman Posted February 14, 2012 Report Share Posted February 14, 2012 HI, I guess this is true. In UVM-1.1, I can't find assign_vif but uvm_config_db. It is said uvm-1.2 will come soon, don't know what will be changed at that time. UVM1.2 may be released around DVcon2012 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.