UVVM support GHDL open source simulator

Hello, I see that GHDL is a supported simulator for UVVM, but does anyone have a step-by-step tutorial how to compile and simulate using GHDL?

Hi,
Yes, UVVM can run with GHDL, but GHDL has to update their compile scripts to support UVVM from release v2019.09.02. From that release most of the VVCs has a Bitvis VIP Scoreboard dependency, i.e. the Scoreboard VIP has to be compiled prior to other VIP src files - see the compile order in VVC quick references, last page. So you can either run GHDL with an earlier release of UVVM or modify the compile order of the UVVM modules in the compile-uvvm.sh/ps1 file.

There have been a while since I used GHDL, but I think the syntax is something like:

DUT files

ghdl -a -frelaxed-rules --std=08 --work=lib …/src/src_file
… and other DUT files…

UVVM Utility, VVC Framework, VIPs

ghdl -a -frelaxed-rules --std=08 --work=uvvm_util …/UVVM/uvvm_util/src/types_pkg.vhd
ghdl -a -frelaxed-rules --std=08 --work=uvvm_util …/UVVM/uvvm_util/src/adaptations_pkg.vhd
… and the other files…

Compile TB

ghdl -a -frelaxed-rules --std=08 --work=TB lib …/tb/TB_file

Simulate

ghdl -e -frelaxed-rules --std=08 --work=TB lib TB_entity
ghdl -r -frelaxed-rules --std=08 --work=TB lib TB_entity

Br,
Marius

Thanks for your reply, Marius. I’ll try it over the weekend👍

1 Like

Hi,

I want to start using GHDL with UVVM. I have problems on compiling uvvm_util on Windows. I tried to run compile.sh in git bash for UVVM_Light-master in scripts folder but couldnt succeed.

I tried using ghdl commands by obeying the orders in compile_order.txt. In windows console, I run these scripts inside src_util folder:

ghdl -a -frelaxed-rules --std=08 -Wno-hide -Wno-shared --work=uvvm_util types_pkg.vhd
ghdl -a -frelaxed-rules --std=08 -Wno-hide -Wno-shared --work=uvvm_util adaptations_pkg.vhd

ghdl -a -frelaxed-rules --std=08 -Wno-hide -Wno-shared --work=uvvm_util uvvm_util_context.vhd

Then redirect the consolde to the folder where my testbench code is there. I tried running testbench code, in which there are lines:

library uvvm_util;
context uvvm_util.uvvm_util_context;

However GHDL gives error such as:

tb_half_adder.vhd:5:9: cannot find resource library “uvvm_util”
tb_half_adder.vhd:6:19: unit “uvvm_util_context” not found in library “uvvm_util”
tb_half_adder.vhd:11:28: entity ‘tb_half_adder’ was not analyzed

so I assume uvvm_util library compilation is not completed successfully. Maybe I miss a simple point. Any help would be appreciated.

Regards,

Burak

I also tried source compile.sh, it gives no error in git bash. I tried running my testbench on git bash but still got the same error “cannot find resource library uvvm_util”

well for some reason i forgot to add std.env to testbench

library STD;
use std.env.all;

maybe it cause the problem, i will try at home if it is the problem

regards

Burak

Hi,
Did you solve the problem?

Br,
Marius

i quit using ghdl and download free version of intel’s modelsim 19.1. i had no problem in modelsim, even posted about how to use UVVM in modelsim in my personal webpage:

https://www.mehmetburakaykenar.com/a-uvvm-example-uart-transmitter-testbench-simulation-on-modelsim/128/

Regards,

Burak

20 Ara 2021 Pzt 23:41 tarihinde Marius via UVVM <uvvm@discoursemail.com> şunu yazdı:

1 Like