The HDL compile programs, xvhdl, xvlog, and xelab, use the xsim.ini configuration file to find the definitions and physical locations of VHDL and Verilog logical libraries.
The compilers attempt to read xsim.ini from these locations in the following order:
-
xsim.iniin current working directory - User-file specified through the
-initfileswitch. If-initfileis not specified, the program searches for xsim.ini in the current working directory. - <Vivado_Install_Dir>/data/xsim
The xsim.ini file has the following syntax:
<logical_library1> = <physical_dir_path1>
<logical_library2> = <physical_dir_path2>
The following is an example xsim.ini file:
std=<Vivado_Install_Area>/xsim/vhdl/std
ieee=<Vivado_Install_Area>/xsim/vhdl/ieee
vl=<Vivado_Install_Area>/xsim/vhdl/vl
ieee_proposed=$RDI_DATADIR/xsim/vhdl/ieee_proposed
synopsys=<Vivado_Install_Area>/xsim/vhdl/synopsys
uvm=<Vivado_Install_Area>/xsim/system_verilog/uvm
unisim=<Vivado_Install_Area>/xsim/vhdl/unisim
unimacro=<Vivado_Install_Area>/xsim/vhdl/unimacro
unifast=<Vivado_Install_Area>/xsim/vhdl/unifast
simprims_ver=<Vivado_Install_Area>/xsim/verilog/simprims_ver
unisims_ver=<Vivado_Install_Area>/xsim/verilog/unisims_ver
unimacro_ver=<Vivado_Install_Area>/xsim/verilog/unimacro_ver
unifast_ver=<Vivado_Install_Area>/xsim/verilog/unifast_ver
secureip=<Vivado_Install_Area>/xsim/verilog/secureip
work=./work
The xsim.ini file has the following features and limitations:
- There must be no more than one library path per line inside the xsim.ini file.
- If the directory corresponding to the physical path does not exist,
xvhdorxvlogcreates it when the compiler first tries to write to that path. - You can describe the physical path in terms of environment variables. The environment variable must start with the
$character. - The default physical directory for a logical library is xsim/<language>/<logical_library_name>,
for example, a logical library name
of:
<Vivado_Install_Area>/xsim/vhdl/unisim - File comments must start with --.Note: From 2018.2 release onwards, Xilinx provides two init files named as
xsim.iniandxsim_legacy.ini. Thexsim_legacy.inifile is similar toxsim.iniof older version. It contains mapping for UNISIM library while the newxsim.inifile contains mapping for all the files of UNISIM library along with the mapping for pre-compiled IP.