OSVVM / OSVVM-Scripts

OSVVM project simulation scripts. Scripts are tedious. These scripts simplify the steps to compile your project for simulation
Other
10 stars 14 forks source link

Running simulation with GHDL and Vivado libraries #49

Closed TylerD83 closed 11 months ago

TylerD83 commented 11 months ago

Hi,

in my project, I included unisim and unimacro libraries from Vivado. When I start a simulation I get following types of error messages:

Error: C:/Xilinx/Vivado/2023.1/data/vhdl/src/unisims/retarget/RAMB18.vhd:23:10: use of synopsys pack age "std_logic_signed" needs the -fsynopsys option Error: ../../src/vital2000/timing_p.vhdl:152:14:note: (you can use -frelaxed to turn this error into a warning)

As a workaround I updated line 216 of VendorScripts_GHDL.tcl: set LocalElaborateOptions [concat --std=${VhdlShortVersion} --syn-binding -fsynopsys -frelaxed {*}${ExtendedElaborateOptions} {*}${CoSimElaborateOptions} --work=${LibraryName} --workdir=${GHDL_WORKING_LIBRARY_PATH} ${VHDL_RESOURCE_LIBRARY_PATHS} {*}${args}]

I don't think hard-coded options are the right solution in this case. Any proposal how to solve it right?

JimLewis commented 11 months ago

See the Script_user_guide.pdf in the Documentation repository. The should be a SetExtendedElaborateOptions that you can put in your LocalScriptDefaults.tcl.

I am on travel today, but that should point you in the right direction.

In LocalScriptDefaults.tcl you can have conditionals that do things only for one simulator - such as ghdl

TylerD83 commented 11 months ago

Thanks alot. This helped. 👍