mirror of
https://github.com/openhwgroup/cve2.git
synced 2025-04-22 04:57:25 -04:00
[DV] Update flow to match RISCV-DV changes (#487)
Signed-off-by: Udi <udij@google.com>
This commit is contained in:
parent
6a582cc11f
commit
1040d5e7e9
3 changed files with 13 additions and 2 deletions
|
@ -103,6 +103,7 @@ iss_sim:
|
|||
cd ${GEN_DIR}; \
|
||||
python3 ./run.py \
|
||||
--o=${OUT}/instr_gen ${GEN_OPTS} \
|
||||
--riscv_dv_root=${GEN_DIR} \
|
||||
--steps=iss_sim \
|
||||
${COMMON_OPTS} \
|
||||
--iss=${ISS} \
|
||||
|
@ -113,6 +114,7 @@ compile:
|
|||
mkdir -p ${OUT}/rtl_sim
|
||||
python3 ./sim.py \
|
||||
--o=${OUT} \
|
||||
--riscv_dv_root=${GEN_DIR} \
|
||||
--steps=compile \
|
||||
${COMMON_OPTS} \
|
||||
--simulator=${SIMULATOR} \
|
||||
|
@ -124,6 +126,7 @@ rtl_sim:
|
|||
mkdir -p ${OUT}/rtl_sim
|
||||
python3 ./sim.py \
|
||||
--o=${OUT} \
|
||||
--riscv_dv_root=${GEN_DIR} \
|
||||
--steps=sim \
|
||||
${COMMON_OPTS} \
|
||||
--simulator=${SIMULATOR} \
|
||||
|
|
|
@ -83,6 +83,12 @@ def process_ibex_sim_log(ibex_log, csv, full_trace = 1):
|
|||
rv_instr_trace.rs1 = n.group("rs1")
|
||||
rv_instr_trace.rs1_val = gpr[rv_instr_trace.rs1]
|
||||
rv_instr_trace.imm = get_imm_hex_val(n.group("imm"))
|
||||
elif rv_instr_trace.instr in ['c.jal']:
|
||||
rv_instr_trace.imm = get_imm_hex_val("0x" + operands[0])
|
||||
elif rv_instr_trace.instr in ['jal']:
|
||||
rv_instr_trace.rd = operands[0]
|
||||
rv_instr_trace.rd_val = gpr[rv_instr_trace.rd]
|
||||
rv_instr_trace.imm = get_imm_hex_val("0x" + operands[1])
|
||||
else:
|
||||
assign_operand(rv_instr_trace, operands, gpr)
|
||||
|
||||
|
|
|
@ -217,6 +217,8 @@ parser = argparse.ArgumentParser()
|
|||
|
||||
parser.add_argument("--o", type=str, default="./out",
|
||||
help="Output directory name")
|
||||
parser.add_argument("--riscv_dv_root", type=str, default="",
|
||||
help="Root directory of RISCV-DV")
|
||||
parser.add_argument("--testlist", type=str, default="riscv_dv_extension/testlist.yaml",
|
||||
help="Regression testlist")
|
||||
parser.add_argument("--test", type=str, default="all",
|
||||
|
@ -259,8 +261,8 @@ subprocess.run(["mkdir", "-p", output_dir])
|
|||
|
||||
# Process regression test list
|
||||
matched_list = []
|
||||
process_regression_list(args.testlist, args.test,
|
||||
args.iterations, matched_list)
|
||||
process_regression_list(args.testlist, args.test, args.iterations,
|
||||
matched_list, args.riscv_dv_root)
|
||||
if len(matched_list) == 0:
|
||||
sys.exit("Cannot find %s in %s" % (args.test, args.testlist))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue