Entity: | Interface |
---|---|
Architecture: | Implementation, behavior, function |
Configuration: | Model chaining, structure, hierarchy |
Process: | Concurrency, event controlled |
Package: | Modular design, standard solution, data types, constants |
Library: | Compilation, object code |
The main units in VHDL are entities, architectures, configurations and packages (together with package bodies).
While an entity describes an interface consisting of the port list most of the time, an architecture contains the description of the function of the corresponding module. In general, a configuration is used for simulation purposes, only. In fact, the configuration is the only simulatable object in VHDL as it explicitly selects the entity/architecture pairs to build the complete model. Packages hold the definition of commonly used data types, constants and subprograms. By referencing a package, its content can be accessed and used.
Another important construct is the process. While statements in VHDL are generally concurrent in nature, this construct allows for a sequential execution of the assignments. The process itself, when viewed as a whole object, is concurrent. In reality, the process code is not always executed. Instead, it waits for certain events to occur and is suspended most of the time.
A library in VHDL is the logical name of a collection of compiled VHDL units (object code). This logical name has to be mapped by the corresponding simulation or synthesis tool to a physical path on the file system of the computer.
VHDL unit | PCB analogy |
---|---|
Entity | Footprint |
Component declaration | Chip socket |
Component Instantiation | Package |
Architecture | Chip die |
Entity | Architecture | Process/ Subprogram | Package | |
---|---|---|---|---|
Subprogram | x | x | x | x |
Component | x | x | ||
Configuration | x | |||
Constant | x | x | x | x |
Data Type | x | x | x | x |
Port | x | |||
Signal | x | xa | x | |
Variable | xb |
a. Signals may not be declared in functions
b. Global variables (VHDL’93) may also be declared in entities, architectures and packages
The table lists the legal places for the declaration of different objects: