Skip to content

Commit

Permalink
Change: Update README files
Browse files Browse the repository at this point in the history
New: add wba test updates from memfy_opt branch
  • Loading branch information
dpretet committed Sep 6, 2023
1 parent fa88568 commit e4203d6
Show file tree
Hide file tree
Showing 16 changed files with 845 additions and 54 deletions.
17 changes: 0 additions & 17 deletions doc/verification.md

This file was deleted.

10 changes: 4 additions & 6 deletions test/apps/README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
# Apps Tetsuite
# Apps Testsuite

## Overview

This testsuite is composed by several applications, stressing out C toolchain and
benchmarking the core.

The testbench provides onl;y "platform" support (CPU + AXI4 interconnect). The application
The testbench provides only "platform" support (CPU + AXI4 interconnect). The applications
are interactive and require user inputs.

To execute the flow:
Expand All @@ -14,11 +14,9 @@ To execute the flow:
./run.sh --tc tests/repl.v
```

For the moment only a REPL aaplication is available and under desgn.

All the testcases rely on [SVUT](https://github.com/dpretet/svut) and use
All the testcases rely on [SVUT](https://github.com/dpretet/svut) and
[Icarus Verilog](http://iverilog.icarus.com) or [Verilator](https://github.com/verilator).

[Common](tests/common) folder contains a Makefile and a linker setup shared between
all the testcases and symlinked into each test folder. A C runtime (crt0.S) is also provided
to applications to boot the processor, initialize the stack and jump to the main.
to boot the processor, initialize the stack and jump to the main.
21 changes: 11 additions & 10 deletions test/c_testsuite/README.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,26 @@
# C Tetsuite
# C Testsuite

## Overview

This testsuite is composed by several applications, stressing out C toolchain and
benchmarking the core.
verifying the core. The testsuite is made of various C code, verifying the basics
of C lang and its support with a hart.

The testbench provides two configurations:

- core: the hart is connected upon an AXI4-lite dual port RAM model, the instruction
bus on one port, the data bus on the other
- platform: the core is connected upon an AXI4 crossbar with some peripherals
(GPIOs, UART, CLINT) and share the same master interface to the AXI4-lite RAM molde
- `core`: the hart is connected upon an AXI4-lite dual port RAM model, the instruction
bus on one port, the data bus on the other. Nothing else than a hart.
- `platform`: the core is connected upon an AXI4 crossbar with some peripherals
(GPIOs, UART, CLINT) and share the same master interface to the AXI4-lite RAM model

To execute the flow:

```bash
./run.sh --tb "CORE" // to run the core only simulation
./run.sh --tb "PLATFORM" // to run the platform, the core + the peripherals
./run.sh --tb "core" // to run the core-only simulation
./run.sh --tb "platform" // to run the platform, the core + the peripherals
```

This will make all programs in tests\* folders, copy the RAM content generated,
This will make all programs in tests/* folders, copy the RAM content generated,
convert it to Verilog format then execute SVUT to run the testbench on each
testcase.

Expand All @@ -29,7 +30,7 @@ For more information about the bash front-end flow:
./run.sh -h
```

All the testcases rely on [SVUT](https://github.com/dpretet/svut) and use
All the testcases rely on [SVUT](https://github.com/dpretet/svut) and
[Icarus Verilog](http://iverilog.icarus.com) or [Verilator](https://github.com/verilator).

[Common](tests/common) folder contains a Makefile and a linker setup shared between
Expand Down
6 changes: 3 additions & 3 deletions test/common/functions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -157,11 +157,11 @@ get_defines() {
gather_result() {

ec=$(grep -c "ERROR:" tc.log)

if [ "$2" -eq 1 ] || [ "$ec" != 0 ]; then
ts_res="${ts_res}$1: ❌\n"
ts_res="${ts_res} - $1:\t❌\n"
else
ts_res="${ts_res}$1: ✅\n"
ts_res="${ts_res} - $1:\t✅\n"
fi
}
#------------------------------------------------------------------------------
Expand Down
9 changes: 6 additions & 3 deletions test/riscv-tests/README.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,21 @@
# RISCV-Tests

Official compliance testsuite from [RISCV](https://github.com/riscv/riscv-tests/)
Official compliance testsuite from [RISCV test github](https://github.com/riscv/riscv-tests/).

To execute the flow:

```bash
./run.sh --simulator icarus
./run.sh --simulator verilator
./run.sh --tb platform
./run.sh --tb core
```

This will make all programs in tests\* folders, copy the RAM content generated,
This will make all programs in tests/* folders, copy the RAM content generated,
convert it to Verilog format then execute SVUT to run the testbench on each
testcase.

All the testcases rely on [SVUT](https://github.com/dpretet/svut) and use
All the testcases rely on [SVUT](https://github.com/dpretet/svut) and
[Icarus Verilog](http://iverilog.icarus.com) or [Verilator](https://github.com/verilator).

[Common](../common) folder contains a Makefile and a linker setup shared between
Expand Down
31 changes: 18 additions & 13 deletions test/wba_testsuite/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,29 +4,26 @@ WBA testsuite is an example of integration of the processor core in a complete e

The testbench provides two configurations:

- core: the hart is connected upon an AXI4-lite dual port RAM model, the instruction
bus on one port, the data bus on the other
- platform: the core is connected upon an AXI4 crossbar with some peripherals
- `core`: the hart is connected upon an AXI4-lite dual port RAM model, the instruction
bus on one port, the data bus on the other. Hart-only configuration.
- `platform`: the core is connected upon an AXI4 crossbar with some peripherals
(GPIOs, UART, CLINT) and share the same master interface to the AXI4-lite RAM molde

For both setup, the test vectors are created from ASM programs, built and then
converted into files to initialize the RAMs.

The intent of this flow is to create programs to stress the IP's core
with a white-box strategy.
with a white-box strategy, very driven by the architecture.

To execute the flow:

```bash
./run.sh --tb "CORE" // to run the core only simulation
./run.sh --tb "PLATFORM" // to run the platform, the core + the peripherals
./run.sh --tb "core" // to run the core-only simulation
./run.sh --tb "platform" // to run the platform, the core + the peripherals
```

This will make all programs in tests\* folders, copy the RAM content generated,
This will make all programs in tests/* folders, copy the RAM content generated,
convert it to Verilog format then execute SVUT to run the testbench on each
testcase.

All the testcases rely on [SVUT](https://github.com/dpretet/svut) and use
All the testcases rely on [SVUT](https://github.com/dpretet/svut) and
[Icarus Verilog](http://iverilog.icarus.com) or [Verilator](https://github.com/verilator).

For more information about the bash front-end flow:
Expand Down Expand Up @@ -82,10 +79,18 @@ to failure in control unit.
Stresses out outstanding requests management in Memfy module when issuing
multiple read or write requests.

# Test 7: RDCYCLE/RDTIME and RDINSTRET
## Test 7: RDCYCLE/RDTIME and RDINSTRET

Checks instret, cycle and time are incremented accordingly the spec

# Test 8: WFI
## Test 8: WFI

Setup interrupt and checks the core manages EIRQ correctly.

## Test 9: M extension

Check multiply /division extension

## Test 10: load / store collision

Stresses out read / write with memfy and check collisions don't occur
1 change: 0 additions & 1 deletion test/wba_testsuite/tests/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ all: $(tests_dump)
clean:
rm -rf $(junk)
rm -fr *.elf
rm -fr *.v
rm -fr *.dump
rm -fr *.gtkw
rm -fr *.vcd
59 changes: 59 additions & 0 deletions test/wba_testsuite/tests/rv32ui-p-test10.v
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
@00010000
6F 00 80 04 73 2F 20 34 93 0F 80 00 63 08 FF 03
93 0F 90 00 63 04 FF 03 93 0F B0 00 63 00 FF 03
13 0F 00 00 63 04 0F 00 67 00 0F 00 73 2F 20 34
63 54 0F 00 6F 00 40 00 93 E1 91 53 17 1F 00 00
23 22 3F FC 6F F0 9F FF 93 00 00 00 13 01 00 00
93 01 00 00 13 02 00 00 93 02 00 00 13 03 00 00
93 03 00 00 13 04 00 00 93 04 00 00 13 05 00 00
93 05 00 00 13 06 00 00 93 06 00 00 13 07 00 00
93 07 00 00 13 08 00 00 93 08 00 00 13 09 00 00
93 09 00 00 13 0A 00 00 93 0A 00 00 13 0B 00 00
93 0B 00 00 13 0C 00 00 93 0C 00 00 13 0D 00 00
93 0D 00 00 13 0E 00 00 93 0E 00 00 13 0F 00 00
93 0F 00 00 73 25 40 F1 63 10 05 00 97 02 00 00
93 82 02 01 73 90 52 30 73 50 00 18 97 02 00 00
93 82 02 02 73 90 52 30 B7 02 00 80 93 82 F2 FF
73 90 02 3B 93 02 F0 01 73 90 02 3A 73 50 40 30
97 02 00 00 93 82 42 01 73 90 52 30 73 50 20 30
73 50 30 30 93 01 00 00 97 02 00 00 93 82 C2 EE
73 90 52 30 13 05 10 00 13 15 F5 01 63 4C 05 00
0F 00 F0 0F 93 01 10 00 93 08 D0 05 13 05 00 00
73 00 10 00 93 02 00 00 63 8A 02 00 73 90 52 10
B7 B2 00 00 93 82 92 10 73 90 22 30 73 50 00 30
97 02 00 00 93 82 42 01 73 90 12 34 73 25 40 F1
73 00 20 30 6F 00 40 00 93 01 A0 00 13 0A 0A 00
93 8A 1A 00 13 0B 2B 00 93 8B 3B 00 13 0C 4C 00
93 8C 5C 00 13 0D 6D 00 93 8D 7D 00 13 0E 8E 00
93 8E 9E 00 93 01 B0 00 23 20 40 01 23 22 50 01
23 24 60 01 23 26 70 01 23 28 80 01 23 2A 90 01
23 2C A0 01 23 2E B0 01 23 20 C0 03 23 22 D0 03
93 01 C0 00 03 25 00 00 83 25 40 00 03 26 80 00
83 26 C0 00 03 27 00 01 83 27 40 01 03 28 80 01
83 28 C0 01 03 29 00 02 83 29 40 02 63 16 45 0D
63 94 55 0D 63 12 66 0D 63 90 76 0D 63 1E 87 0B
63 9C 97 0B 63 1A A8 0B 63 98 B8 0B 63 16 C9 0B
63 94 D9 0B 93 01 50 01 13 02 00 00 93 02 00 00
13 03 00 00 93 03 40 06 13 00 00 00 13 02 12 00
23 20 40 00 03 23 00 00 93 82 12 00 E3 98 72 FE
63 1C 73 06 93 01 60 01 13 02 00 00 93 02 00 00
13 03 00 00 93 03 00 00 13 04 00 00 23 20 00 00
23 22 00 00 93 04 40 06 13 00 00 00 93 82 12 00
23 20 50 00 03 23 40 00 93 82 12 00 23 22 50 00
83 23 00 00 13 02 12 00 E3 12 92 FE 13 94 14 00
63 94 82 02 13 04 10 00 33 84 84 40 13 14 14 00
63 1C 83 00 13 94 14 00 93 04 10 00 33 04 94 40
63 94 83 00 63 12 30 02 0F 00 F0 0F 63 80 01 00
93 91 11 00 93 E1 11 00 93 08 D0 05 13 85 01 00
93 8F 1F 00 73 00 10 00 0F 00 F0 0F 93 01 10 00
93 08 D0 05 13 05 00 00 73 00 10 00 73 00 10 00
73 10 00 C0 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00
@00011000
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00
Loading

0 comments on commit e4203d6

Please sign in to comment.