black-parrot / black-parrot-sim

BSD 3-Clause "New" or "Revised" License
11 stars 7 forks source link

bp-test streaming_accelerator_vdp fails #2

Closed vsteltzer closed 2 years ago

vsteltzer commented 2 years ago

Hi i have a problem executing streaming accelerator tests with the black-parrot-sim repository.

Area: sdk/bp-tests/src/streaming_accelerator_vdp.c

Repository/Branch/Commit: Repo: black-parrot-sim Branch: master Commit: https://github.com/black-parrot/black-parrot-sim/commit/c4f593ffb68a139653c349306576b43c7508fbb7

Current behavior: When executing the vector dot product streaming accelerator test from /rtl/bp_top/syn with make build_dump.sc sim_dump.sc SUITE=bp-tests PROG=streaming_accelerator_vdp CFG=bp_multicore_4_acc_vdp_cfg_p the test gets aborted with the following error.

NBF loader done! Warning: Accessing hio 1. Sending loopback message! [393640000] %Error: bp_nonsynth_host.sv:167: Assertion failed in testbench.testbench.host: Warning: Accesing illegal hio 1. Sending loopback message! %Error: /home/*****/rtl/bp_top/test/common/bp_nonsynth_host.sv:167: Verilog $stop Aborting... Aborted (core dumped)

When checking the test with dromajo from the ./sdk folder with ./install/bin/dromajo --host ./prog/bp-tests/streaming_accelerator_vdp.riscv i get the error message

riscv_cpu_write_memory: invalid physical address 0x000000000020001c mcause: 0x0000000000000007 mtval: 0x000000000020001c mepc: 0x0000000080000594 Unhandled machine-mode trap [CORE0 FSH] FAIL instret: 4715

Is this error only on my side or do you experience the same behaviour? What could i do to fix this and get the example up and running?

dpetrisko commented 2 years ago

Hi, which version of Verilator are you using?

vsteltzer commented 2 years ago

I am using the verilator version linked in the rtl repo which is the commit d384a69 in the verilator repo, which is v4.218 i believe.

dpetrisko commented 2 years ago

CFG=bp_multicore_4_acc_vdp_cfg_p -> CFG=e_bp_multicore_4_acc_vdp_cfg

Dromajo has no concept of accelerators included, so these programs will not work on standalone dromajo. However, they should work with COSIM because the DUT overrides accesses to MMIO

vsteltzer commented 2 years ago

Ah that was it. I have mixed up the CFGs, now it works!

Thank you very much for your help!