Commit ddb03954 authored by kblantos's avatar kblantos

Added: Makefile to run automatically all the AXI tests and README file for explanations

parent 7dd450ae
# This Makefile can be called by the Continuous Integration (CI) tool to execute all
# testbenches added for CI
# AXI4 cores
TB_DIRS+=axi/axi4lite_wb_bridge
TB_DIRS+=axi/z7_axi_gpio_expander
TB_DIRS+=axi/axi4lite32_axi4full64_bridge
TB_DIRS+=axi/axi4lite_axi4full_bridge
.PHONY: $(TB_DIRS)
all: $(TB_DIRS) summary
$(TB_DIRS):
@echo "Compime OSVVM"
cd "$@"; \
/usr/local/lib/ghdl/vendors/compile-osvvm.sh --all 2>&1
@echo $@
@echo "Run HDLMAKE"
cd "$@"; \
hdlmake 2>&1
@echo "Run make"
$(MAKE) -C $@ $(TARGET)
@echo "Run ghdl"
cd "$@" ;\
./run.sh
echo "ghdl returned $$?"
summary: $(TB_DIRS)
@echo "-------------------------------------------------------------------"
@echo "Summary:"
@for d in $(TB_DIRS); do \
if [ -f $$d/transcript ]; then \
echo "Warnings for $$d:"; \
cat $$d/transcript | grep Warning; \
if [ $$? -eq 1 ]; then echo "None"; fi ;\
echo "Errors for $$d:"; \
cat $$d/transcript | grep Error; \
if [ $$? -eq 1 ]; then echo "None"; fi ;\
else \
echo "No transcript file for $$d"; \
fi \
done
clean:
@for d in $(TB_DIRS); do \
if [ -f $$d/Makefile ]; then \
$(MAKE) -C $$d $@; \
rm -f $$d/Makefile; \
fi \
done
# Description
The majority of the general cores have their own testbench written in VHDL and as a verification methodology, OSVVM is used. There are also some testbenches which are written in SystemVerilog.
The common features of each test are:
- Randomization of the input signals
- FSM coverage (when there are FSM in the RTL design), results are shown at the end of the simulation
- Assertions are used to verify aspects of the core's functionality, cumply with the specifications
There are two options for the users, in order to run these tests. First is to run them all by using the Makefile in the current directory. This Makefile contains all the VHDL tests. Second option, is to run each test individually.
## Requirements
- [hdlmake](https://hdlmake.readthedocs.io/en/master/#install-hdlmake-package)
- [ghdl](https://ghdl.github.io/ghdl/development/building/index.html#build)
- [OSVVM](https://github.com/OSVVM/OSVVM) version 2020.05+
## Set up environment
- Modify the file **/usr/local/lib/ghdl/vendors/config.sh** by adding the OSVVM path (in OSVVM_settings change the Installation Directory)
- Compile OSVVM:
```console
/usr/local/lib/ghdl/vendors/compile-osvvm --all
```
## How to test
```console
hdlmake makefile
make
./run.sh
```
Waveform option:
```console
./run.sh --wave=waveform.ghw
```
## Maintainer
- [Konstantinos Blantos](mailto:konstantinos.blantos@cern.ch)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment