Vivado Simulatorを使ってUVMに入門している。とりあえず良い資料が無いので以下のサイトを見ながら我流でいろいろ試している。
UVM Driver / Agent / monitor / Sequencer を以下のように配置した。
. |-- Makefile |-- model | |-- sample.svh | |-- sample_agent.sv | |-- sample_driver.sv | |-- sample_env.sv | |-- sample_model.svh | |-- sample_monitor.sv | `-- sample_sequencer.sv |-- sample_test.sv `-- tb_top.sv
それぞれのファイルの内容は上記のウェブサイトに書いてあるので、Vivado Simulatorを動かすためのMakefileだけ掲載しておく。
.PHONY: all FILELIST = FILELIST += tb_top.sv all: xvlog -sv $(FILELIST) -L uvm --include ./model/ xelab tb_top -timescale 1ns/100ps -L uvm xsim tb_top -R --testplusarg "UVM_TESTNAME=sample_test" clean: rm -rf *.log *.jou *.dir *.pb
実行結果は以下のようになった。
UVM_INFO /proj/xbuilds/SWIP/2020.2_0711_1805/installs/lin64/Vivado/2020.2/data/system_verilog/uvm_1.2/xlnx_uvm_package.sv(18648) @ 0: reporter [NO_DPI_TSTNAME] UVM_NO_DPI defined--getting UVM_TESTNAME directly, without DPI UVM_INFO @ 0: reporter [RNTST] Running test sample_test... UVM_INFO /proj/xbuilds/SWIP/2020.2_0711_1805/installs/lin64/Vivado/2020.2/data/system_verilog/uvm_1.2/xlnx_uvm_package.sv(20867) @ 0: reporter [UVM/COMP/NAMECHECK] This implementation of the component name checks requires DPI to be enabled UVM_INFO @ 0: uvm_test_top [TEST] Hello World UVM_INFO @ 0: uvm_test_top.env [ENV] Hello ENV UVM_INFO @ 0: uvm_test_top.env.agent [AGENT] Hi UVM_INFO @ 0: uvm_test_top.env.agent.sequencer [SEQR] Hi UVM_INFO @ 0: uvm_test_top.env.agent.monitor [MONITOR] Hi UVM_INFO @ 0: uvm_test_top.env.agent.driver [DRIVER] Hi UVM_INFO /proj/xbuilds/SWIP/2020.2_0711_1805/installs/lin64/Vivado/2020.2/data/system_verilog/uvm_1.2/xlnx_uvm_package.sv(13673) @ 0: reporter [UVM/REPORT/SERVER] [UVM/RELNOTES] 1