How To: Set up IEEE Standard Precompiled Libraries

Modified on Wed, 28 May at 11:26 AM

How To: Set up IEEE Standard Precompiled Libraries

DSim comes with the VHDL IEEE-1987, IEEE-1993, and IEEE-2008 standard libraries precompiled.


The following are the packages in the precompiled VHDL IEEE-1987 standard library:


  • numeric_bit
  • numeric_std
  • std_logic_1164
  • vital_primitives
  • vital_timing

The following are the packages in the precompiled VHDL IEEE-1993 standard library:


  • math_complex
  • math_real
  • numeric_bit
  • numeric_std
  • std_logic_1164
  • std_logic_arith
  • std_logic_misc
  • std_logic_signed
  • std_logic_textio
  • std_logic_unsigned
  • vital_memory
  • vital_primitives
  • vital_timing

The following are the packages in the precompiled VHDL IEEE-2008 standard library:


  • fixed_float_types
  • fixed_generic_pkg
  • fixed_pkg
  • float_generic_pkg
  • float_pkg
  • ieee_bit_context
  • ieee_std_context
  • math_complex
  • math_real
  • numeric_bit
  • numeric_bit_unsigned
  • numeric_std
  • numeric_std_unsigned
  • std_logic_1164
  • std_logic_arith
  • std_logic_signed
  • std_logic_textio
  • std_logic_unsigned
  • vital_memory
  • vital_primitives
  • vital_timing

By default, the precompiled VHDL IEEE-1993 standard library is mapped to your local project. To change the version of the IEEE library, and hence the version of VHDL used by your design, go to the appropriate section for your tool.



DSim Studio

To change the version of the IEEE library mapped to your project:


1. Under LIBRARIES, right-click the library $STD_LIBS\ieee93 and click Remove Library Search Path.



2. Hover to the right of LIBRARIES and click the + sign to Add Library Search Path.



3. Enter one of the following in the Search Path and click Save:


  • $STD_LIBS\ieee08 for the IEEE-2008 library
  • $STD_LIBS\ieee93 for the IEEE-1993 library
  • $STD_LIBS\ieee87 for the IEEE-1987 library

4. The library you entered now appears under LIBRARIES. For example, $STD_LIBS\ieee08.



5. Repeat the procedure if you want to switch the IEEE library.


6. When you compile a VHDL file, DSim will interpret it as VHDL-1993 by default, using whatever version of the IEEE library you've mapped. In order to interpret the file as a different version of VHDL, add the appropriate option to the file's configuration:


  • -vhdl2008 for VHDL-2008
  • -vhdl93 for VHDL-1993
  • -vhdl87 for VHDL-1987


DSim

To change the version of the IEEE library mapped to your project:


1. In a terminal, enter one of the following commands from where DSim will be invoked, to change the environment variable DSIM_FE_PATH:



DSim Studio shell or Windows PowerShell

  • $Env:DSIM_FE_PATH="$Env:STD_LIBS\ieee08" for the IEEE-2008 library
  • $Env:DSIM_FE_PATH="$Env:STD_LIBS\ieee93" for the IEEE-1993 library
  • $Env:DSIM_FE_PATH="$Env:STD_LIBS\ieee87" for the IEEE-1987 library

Linuxs Bash shell

  • export DSIM_FE_PATH=${STD_LIBS}/ieee08 for the IEEE-2008 library
  • export DSIM_FE_PATH=${STD_LIBS}/ieee93 for the IEEE-1993 library
  • export DSIM_FE_PATH=${STD_LIBS}/ieee87 for the IEEE-1987 library

2. Check that the correct library is mapped by entering:


dlib ls


3. Repeat the procedure if you want to switch the IEEE library.


4. When you compile a VHDL file, DSim will interpret it as VHDL-1993 by default, using whatever version of the IEEE library you've mapped. In order to interpret the file as a different version of VHDL, add the appropriate option to your dvhcom command:


  • -vhdl2008 for VHDL-2008
  • -vhdl93 for VHDL-1993
  • -vhdl87 for VHDL-1987

DSim Cloud

The version of the IEEE library mapped to your project is set by the version field entry in your mdc_config.yml:


 

    - name: ieee
    version: "93"

 

To change the version of the IEEE library mapped to your project:


1. Change the version field of the entry to one of the following and save mdc_config.yml:


  • 08 for the IEEE-2008 library
  • 93 for the IEEE-1993 library
  • 87 for the IEEE-1987 library

For example:


 

    - name: ieee  
    version: "08"

 

To see how to change your mdc_config.yml, see DSim Cloud Configuration.


2. When you compile a VHDL file, DSim will interpret it as VHDL-1993 by default, using whatever version of the IEEE library you've mapped. In order to interpret the file as a different version of VHDL, add the appropriate option to your dvhcom command:


  • -vhdl2008 for VHDL-2008
  • -vhdl93 for VHDL-1993
  • -vhdl87 for VHDL-1987

Optional

To see the components inside the mapped IEEE library, enter this command in a terminal:


 

dlib -a 'ls -lib ieee'

 

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article