Interview DV
Interview DV
A. struct is a collection of different data types where separate memory will be created for
each datatype whereas for union only the highest memory datatype memory will be
created.
11) What is the difference between $display, $write, $monitor and $strobe in
SystemVerilog?
A. 1) $display : Print the values immediately when executed.
2) $strobe : Print the values at the end of the current timestep.
3) $monitor : Print the values at the end of the current timestep if any values
change. If $monitor is called more than once, the last call will override previous one.
4) $write : This is same as $display but doesn't terminate with a newline (\n).
12) Regions of sv
A. Preponed ,Active, Inactive, NBA, Observed, Re-active, Re-inactive,Re-NBA, Postpned
A. UVM uses standard phases to order the major steps that take place during simulation.
There are three groups of phases, which are executed in the following order.
1. Build phases - In the build phases; the testbench is configured and constructed. It
has following sub-phases which are all implemented as virtual methods in
uvm_component base class.
1) build_phase()
2) connect_phase()
3) end_of_elaboration()
2. Run time phases - These phases can consume time and this is where most of the
test execution happens.
1) start_of_simulation()
2) run_phase()
The run_phase() is further divided into 12 sub-phases as below:
1) pre_reset
2) reset
3) post_reset
4) pre_configure
5) configure
6) post_configure
7) pre_main
8) main
9) post_main
10) pre_shutdown
11) shutdown
12) post_shutdown
3. Clean up phase - This phase execute after the test ends and is used to collect, and
report results and statistics from the test. This consists of following sub phases:
1) extract()
2) check()
3) report()
4) final()
15) What are the different arbitration mechanisms available for a sequencer?
A. 1) SEQ_ARB_FIFO (Default if none specified). If this arbitration mode is specified, then
the sequencer picks sequence items in a FIFO order from all sequences running on the
sequencer. For Example: if seq1, seq2 and seq3 are running on a sequencer, it will pick an
item from seq1 first, followed by seq2, and then seq3 if available, and continue.
2) SEQ_ARB_WEIGHTED: If this arbitration mode is selected, sequence items from the
highest priority sequence are always picked first until none available, then the sequence
items from next priority sequence, and so on. If two sequences have equal priority, then the
items from them are picked in a random order.
3) SEQ_ARB_RANDOM: If this arbitration mode is selected, sequence items from different
sequences are picked in a random order by ignoring all priorities.
4) SEQ_ARB_STRICT_FIFO: This is similar to SEQ_ARB_WEIGHTED except that if two
sequences have same priority, then the items from those sequences are picked in a FIFO
order rather than in a random order.
5) SEQ_ARB_STRICT_RANDOM: This is similar to SEQ_ARB_RANDOM except that the
priorities are NOT ignored.The items are picked randomly from sequences with highest
priority first followed by next and in that order.
6) SEQ_ARB_USER: This algorithm allows a user to define a custom algorithm for arbitration
between sequences.This is done by extending the uvm_sequencer class and overriding the
user_priority_arbitration() method.