For the following class ::
typedef enum { ZERO , ONE , TWO , THREE , FOUR , FIVE } num_t;
class comp_class extends uvm_component ;
protected num_t num = ONE;
// Other properties
`uvm_component_utils_begin(comp_class)
// Other Field Automation Macros here
`uvm_field_enum(num_t, num, UVM_ALL_ON)
`uvm_component_utils_end
// Component Constructor
virtual function void build_phase(uvm_phase phase);
super.build_phase(phase);
....
endfunction
....
endclass
// Within tb_top
initial begin
uvm_config_db#(<arg1>)::set(null , "<arg2>", "<arg3>", FIVE);
run_test();
end
[Q1] From my tb_top, how do I configure property ‘num’ ?
(a) What would arg1 and arg3 ?
(b) Should arg2 be the instance path of ‘comp_class’
[Q2] The call to super.build_phase(phase) in class ‘comp_class’ is necessary to provide the flexibility to set the properties used with field automation macros , right ?