Cook Book Verification
Cook Book Verification
1800.2-2017
1800.2
UVM 1.0 1.1 1.2 Ref Impl
• Reg can appear in map > once uvm_reg_map t_m1 uvm_reg_map t_m2
regA
• unlock_model() uvm_reg_blk blk
finish_item(req);
item_done();
task body();
req = req_t::type_id::create(“req”); task run_phase(uvm_phase phase);
for_int i = 0; i < num; i++) begin forever begin
start_item(req, pri, agent.seqr); seq_item_port.get_next_item(req);
if(!req.randomize()) begin drive_item2bus(req);
`uvm_error(“body”, “rand failure”) seq_item_port.item_done();
end end
finish_item(req); endtask
`uvm_info(“my_seq1”,req.convert2string()); If driver updates req with
end response information
endtask
© 2017 Mentor Graphics Corporation
Solving the UVM "Blank Page" Problem
• Accelerate environment development
• Better environments in less time
• Reusable
• Across projects, sites
• Scalable
• Across design size, complexity,
and target technology
• Emulatable
• Same environment and stimulus
© 2017 Mentor Graphics Corporation
UVM Framework Gets You Going
• UVM Jumpstart
• Reduces barrier to entry for UVM at no cost!
• Be immediately productive while learning UVM
• Focus efforts on verifying custom design
• UVM with Questa on Linux or Windows
• UVM Reuse methodology
• Allows team to focus on verifying product features
• Horizontal reuse of components across projects
• Vertical reuse of environments from block to top
• Start in simulation and reuse in emulation
• Automatic Code Generation
• Interface/environment/bench templates
Class definitions
Interface definitions
Faster Bring-up
Testbench Reuse
Sequencer Slave
Driver DUT Responder
sequence (Proxy) (Proxy) sequence
Emulator Transactions
© 2017 Mentor Graphics Corporation
UVM Acceleration Flow Summary
• Employ two distinct UVM and HDL top level modules
• UVM (or HVL or TB) top must be untimed; HDL top must be synthesizable for emulation
- DUT, pin interfaces, and clock/reset logic can be largely preserved
- Upper testbench layers should remain (largely) unaffected
• Separate file lists for compilation required too!
• Split UVM agent drivers and monitors into untimed UVM proxies and timed HDL BFMs
• BFMs are modeled as SV interfaces accessing separate SV pin interface
- Implemented using implicit FSMs and other XRTL constructs
- Used for testbench-HDL binding instead of (virtual) pin interfaces
• Proxies encapsulate intra-transactor communication
- Hide BFM tasks and functions which are visible only to the proxy
- Represent interface to upper UVM testbench layers (remains unchanged)
- Are generally light-weight, implementing basic threads to pass generated UVM stimulus to HDL side,
and observed HDL responses back to UVM side
• Transaction objects must be converted to/from synthesizable BFM task and function arguments
- Internal to UVM proxies, e.g. using “to_struct” and “from_struct” methods
• Tune emulation-ready testbench for optimal performance
• Profiling and analysis to minimize s/w overhead and maximize h/w frequency
- Reactive vs. streaming, inbound vs. outbound, one-way vs. two-way, concurrency © 2017 Mentor Graphics Corporation
Common Debug from Simulation to Emulation
Visualizer
Visualizer
• Visualizer