Intel® Quartus® Prime Software
Intel® Quartus® Prime Design Software, Design Entry, Synthesis, Simulation, Verification, Timing Analysis, System Design (Platform Designer, formerly Qsys)
17250 Discussions

The library usage in Quartus

Altera_Forum
Honored Contributor II
1,543 Views

In menu of setting, there is a category "Libraries". I have never use any other libraries so this category is always empty. 

 

I just wonder what is the library used for? When I programmed VHDL, we always need to put 

 

LIBRARY IEEE ; 

USE IEEE.STD_LOGIC_1164.ALL; 

 

But in Verilog, we don't need it.  

 

Is the library can be put into category "Libraries" similar as the library IEEE? And how to use library in Verilog? 

 

Thanks.
0 Kudos
8 Replies
Altera_Forum
Honored Contributor II
810 Views

This is just a VHDL library to declare the std_ulogic, std_ulogic_vector (and std_logic etc) types. Because of the VHDL typing rules you cannot do alot without them for synthesisable logic. 

 

The libraries tab in quartus are for user libraries. it also dictates the search path for any .inc files (if for some reason you're using AHDL).  

 

So there is no way to use std_logic_1164 in verilog because it doesnt exist. it is a VHDL only thing because of the way the language works.
0 Kudos
Altera_Forum
Honored Contributor II
810 Views

 

--- Quote Start ---  

This is just a VHDL library to declare the std_ulogic, std_ulogic_vector (and std_logic etc) types. Because of the VHDL typing rules you cannot do alot without them for synthesisable logic. 

 

The libraries tab in quartus are for user libraries. it also dictates the search path for any .inc files (if for some reason you're using AHDL).  

 

So there is no way to use std_logic_1164 in verilog because it doesnt exist. it is a VHDL only thing because of the way the language works. 

--- Quote End ---  

 

 

Thanks very much. Yes, Verilog does not need VHDL library. But user libraries can be used for both in VHDL and Verilog, right? 

 

Another question I have is: what kind of files is inside user libraries? Customized IP?  

 

Thanks.
0 Kudos
Altera_Forum
Honored Contributor II
810 Views

VHDL modules and packages. 

It's a nice way to organize stuff, when you're writing re-usable stuff.
0 Kudos
Altera_Forum
Honored Contributor II
810 Views

 

--- Quote Start ---  

VHDL modules and packages. 

It's a nice way to organize stuff, when you're writing re-usable stuff. 

--- Quote End ---  

 

 

Thanks, so that means even user libraries are only for VHDL? I am a little confused by this. 

 

Thanks again.
0 Kudos
Altera_Forum
Honored Contributor II
810 Views

What are you trying to do? 

All the libraries in Quartus really lets you do is add a search path. I dont really use it, even for reusable stuff.
0 Kudos
Altera_Forum
Honored Contributor II
810 Views

 

--- Quote Start ---  

What are you trying to do? 

All the libraries in Quartus really lets you do is add a search path. I dont really use it, even for reusable stuff. 

--- Quote End ---  

 

 

Hi, I just want to understand what is usage of libraries. I have never use them. I just wonder whether libraries will like libraries in software programming language (such as C++), there are designed modules inside them (definitely no class since there is no class definition in HDL). 

 

As you mentioned, "All the libraries in Quartus really lets you do is add a search path", If I want to use some IPs from third-party vendor (not IP come from Altera), I actually need is the .v or .vhd file of IP, right? 

 

Thanks very much.
0 Kudos
Altera_Forum
Honored Contributor II
810 Views

If you know C++, then it's easy: the concept of a VHDL library is akin to a C++ namespace. That's all. 

In Verilog, there's no notion of this. 

 

If you need to use third-party IP, you'll need some kind of Verilog/VHDL/AHDL file. 

It may not be the original source code, though.
0 Kudos
Altera_Forum
Honored Contributor II
810 Views

 

--- Quote Start ---  

If you know C++, then it's easy: the concept of a VHDL library is akin to a C++ namespace. That's all. 

In Verilog, there's no notion of this. 

 

If you need to use third-party IP, you'll need some kind of Verilog/VHDL/AHDL file. 

It may not be the original source code, though. 

--- Quote End ---  

 

 

That is clear. Thanks very much!
0 Kudos
Reply