[DV] Fix ovpsim compare issue (#355)

* [DV] Fix ovpsim compare issue

* Update some test descriptions to avoid timeouts, update debug test
This commit is contained in:
udinator 2019-09-27 17:45:58 -07:00 committed by GitHub
parent 1615969bc1
commit 074e637b11
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 32 additions and 10 deletions

View file

@ -137,3 +137,22 @@ parameter privileged_reg_t implemented_csr[] = {
DSCRATCH0, // Debug scratch register 0
DSCRATCH1 // Debug scratch register 1
};
// --------------------------------------------------------------------------
// Supported interrupt/exception setting, used for functional coverage
// --------------------------------------------------------------------------
parameter interrupt_cause_t implemented_interrupt[] = {
M_SOFTWARE_INTR,
M_TIMER_INTR,
M_EXTERNAL_INTR
};
parameter exception_cause_t implemented_exception[] = {
INSTRUCTION_ACCESS_FAULT,
ILLEGAL_INSTRUCTION,
BREAKPOINT,
LOAD_ACCESS_FAULT,
STORE_AMO_ACCESS_FAULT,
ECALL_MMODE
};

View file

@ -152,12 +152,12 @@
+no_csr_instr=1
+no_fence=1
+num_of_sub_program=0
+num_debug_sub_program=3
+num_debug_sub_program=2
+randomize_csr=1
rtl_test: core_ibex_debug_intr_basic_test
sim_opts: >
+require_signature_addr=1
+max_interval=2000
+max_interval=3000
+enable_debug_stress_seq=1
compare_opts:
compare_final_value_only: 1
@ -172,11 +172,12 @@
+require_signature_addr=1
+gen_debug_section=1
+no_ebreak=1
+instr_cnt=3000
+instr_cnt=6000
+no_csr_instr=1
+no_fence=1
+no_wfi=0
+randomize_csr=1
+num_of_sub_program=0
rtl_test: core_ibex_debug_wfi_test
sim_opts: >
+require_signature_addr=1
@ -239,6 +240,7 @@
+no_wfi=1
+instr_cnt=6000
+randomize_csr=1
+num_of_sub_program=0
rtl_test: core_ibex_debug_ebreakm_test
sim_opts: >
+require_signature_addr=1

View file

@ -167,6 +167,12 @@ def compare(test_list, iss, output_dir, verbose):
"""
report = ("%s/regr.log" % output_dir).rstrip()
for test in test_list:
compare_opts = test.get('compare_opts', {})
in_order_mode = compare_opts.get('in_order_mode', 1)
coalescing_limit = compare_opts.get('coalescing_limit', 0)
verbose = compare_opts.get('verbose', 0)
mismatch = compare_opts.get('mismatch_print_limit', 5)
compare_final = compare_opts.get('compare_final_value_only', 0)
for i in range(0, test['iterations']):
elf = ("%s/asm_tests/%s.%d.o" % (output_dir, test['test'], i))
logging.info("Comparing %s/DUT sim result : %s" % (iss, elf))
@ -193,12 +199,6 @@ def compare(test_list, iss, output_dir, verbose):
check_ibex_uvm_log(uvm_log, "ibex", test_name, report)
else:
if 'compare_opts' in test:
compare_opts = test.get('compare_opts')
in_order_mode = compare_opts.get('in_order_mode', 1)
coalescing_limit = compare_opts.get('coalescing_limit', 0)
verbose = compare_opts.get('verbose', 0)
mismatch = compare_opts.get('mismatch_print_limit', 5)
compare_final = compare_opts.get('compare_final_value_only', 0)
compare_trace_csv(rtl_csv, iss_csv, "ibex", iss, report,
in_order_mode, coalescing_limit, verbose,
mismatch, compare_final)

View file

@ -10,7 +10,7 @@ class core_ibex_base_test extends uvm_test;
virtual core_ibex_dut_probe_if dut_vif;
mem_model_pkg::mem_model mem;
core_ibex_vseq vseq;
int unsigned timeout_in_cycles = 3000000;
int unsigned timeout_in_cycles = 5000000;
// If no signature_addr handshake functionality is desired between the testbench and the generated
// code, the test will wait for the specifield number of cycles before starting stimulus
// sequences (irq and debug)

View file

@ -346,6 +346,7 @@ class core_ibex_debug_wfi_test extends core_ibex_directed_test;
// is detected, and before any stimulus is sent to the core
forever begin
wait (dut_vif.wfi === 1'b1);
wait (dut_vif.core_sleep === 1'b1);
clk_vif.wait_clks($urandom_range(100));
vseq.start_debug_single_seq();
// After assserting this signal, core should wake up and jump into debug mode from WFI state