Hi Richard, This patchset adds several rvv load/store tests with PMP permission settings, as we discussed during your v1 submission.
While building the tests, I noticed that pmp_hart_has_privs has a scope issue that yields unexpected results. This affects both the vector fault-only-first load and vector unit-stride ld/st instructions. I therefore attempted to correct pmp_hart_has_privs and vext_ldst_us_notail, adding matching tests. Hope these system mode tests and fixes can help you. PS: I tried applying v2 <[email protected]> to the master and riscv-to-apply.next branches, but both conflicted. Thanks, rnax Based-on: <[email protected]> Max Chou (6): target/riscv: Match PMP entries lying inside the checked range target/riscv: rvv: Probe unit-stride accesses by the first element tests/tcg/riscv64: Add vector masked fault-only-first PMP test tests/tcg/riscv64: Add vector unit-stride PMP test tests/tcg/riscv64: Add vector fault-only-first page probe test tests/tcg/riscv64: Add vector segment PMP region spanning test target/riscv/tcg/pmp.c | 31 +-- target/riscv/tcg/vector_helper.c | 45 +++- tests/tcg/riscv64/Makefile.softmmu-target | 38 +++ tests/tcg/riscv64/rvv-ldst.inc | 91 +++++++ tests/tcg/riscv64/test-rvv-ldst-ff-page.S | 83 +++++++ tests/tcg/riscv64/test-rvv-ldst-ff-pmp.S | 259 ++++++++++++++++++++ tests/tcg/riscv64/test-rvv-ldst-seg-pmp.S | 141 +++++++++++ tests/tcg/riscv64/test-rvv-ldst-us-pmp.S | 281 ++++++++++++++++++++++ 8 files changed, 943 insertions(+), 26 deletions(-) create mode 100644 tests/tcg/riscv64/rvv-ldst.inc create mode 100644 tests/tcg/riscv64/test-rvv-ldst-ff-page.S create mode 100644 tests/tcg/riscv64/test-rvv-ldst-ff-pmp.S create mode 100644 tests/tcg/riscv64/test-rvv-ldst-seg-pmp.S create mode 100644 tests/tcg/riscv64/test-rvv-ldst-us-pmp.S -- 2.43.0
