From f6441a2e6f901748b504ef93872649c9463a404e Mon Sep 17 00:00:00 2001 From: Richard Qin Date: Sun, 15 Mar 2026 16:07:39 +0800 Subject: initial commit: project architecture --- rv64cpu/tb/compliance/.gitkeep | 0 rv64cpu/tb/compliance/CMakeLists.txt | 36 ++++++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+) create mode 100644 rv64cpu/tb/compliance/.gitkeep create mode 100644 rv64cpu/tb/compliance/CMakeLists.txt (limited to 'rv64cpu/tb/compliance') diff --git a/rv64cpu/tb/compliance/.gitkeep b/rv64cpu/tb/compliance/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/rv64cpu/tb/compliance/CMakeLists.txt b/rv64cpu/tb/compliance/CMakeLists.txt new file mode 100644 index 0000000..b832f01 --- /dev/null +++ b/rv64cpu/tb/compliance/CMakeLists.txt @@ -0,0 +1,36 @@ +# ─── Compliance Test CMake ─────────────────────────────────────────────────────── +# +# Builds the compliance test runner and registers riscv-arch-test tests. +# +# ───────────────────────────────────────────────────────────────────────────────── + +# The compliance runner needs the SoC sim binary +# Uncomment when both the SoC and compliance_runner are implemented: +# +# add_verilator_target( +# NAME compliance_runner +# TOP_MODULE richard_soc +# SOURCES ${ALL_RTL_SOURCES} +# INCLUDE_DIRS ${RTL_COMMON_INCLUDES} +# TB_SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/compliance_runner.cpp +# EXTRA_FLAGS --threads 2 +# ) +# +# ─── Register individual compliance tests via CTest ────────────────────────────── +# This is done dynamically by the compliance_runner binary and run_compliance.py. +# You can also manually register tests like: +# +# set(RISCV_ARCH_TEST_DIR ${CMAKE_SOURCE_DIR}/sw/riscv-arch-test) +# +# file(GLOB RV64I_TESTS ${RISCV_ARCH_TEST_DIR}/riscv-test-suite/rv64i_m/I/src/*.S) +# foreach(test_src ${RV64I_TESTS}) +# get_filename_component(test_name ${test_src} NAME_WE) +# add_test( +# NAME compliance_rv64i_${test_name} +# COMMAND compliance_runner --test ${test_src} +# ) +# set_tests_properties(compliance_rv64i_${test_name} PROPERTIES +# LABELS "compliance;rv64i" +# TIMEOUT 30 +# ) +# endforeach() -- cgit v1.2.3