-
still learning VHDL, but i've definitely discovered some redunancy between the some people suggest that at the same time, it has been mentioned that question: is this redundancy between |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 1 reply
-
I am no expert when it comes to the syntactic rules of VHDL (I just accept them the way they are 😅). The VHDL gitter channel might be the right place to get more (helpful) information: https://app.gitter.im/#/room/#vhdl_General:gitter.im |
Beta Was this translation helpful? Give feedback.
-
the general consensus in the world is to prefer i've discovered (at least with the GHDL compiler) that the ORDER of the source files matters.... by (redundantly!!!) declaring were we to simply list the source files in a "bottom-up" order (beginning with
as i'm starting to play with some modifications in module interfaces, my own branch has taken this approach.... unless there is a "circular" reference between modules (which is a BAD design, IMHO), this approach will always work.... if the modules are NOT ordered bottom-up, compiler errors about "undefined entities" will help you get things in order 😉 |
Beta Was this translation helpful? Give feedback.
-
@biosbob as you concluded, components are mostly to be used for black-boxes or for configurations. Otherwise, direct entity instantiation is less verbose. Direct instantiation was introduced in VHDL 1993, so it did not exist "since the beginning" (the first revision of the language was in 1987). See: |
Beta Was this translation helpful? Give feedback.
the general consensus in the world is to prefer
entity
overcomponent
, due to this redundancy;component
should only be used in certain advanced cases (such as when mixing VHDL+Verilog or importing some "black-box" IP)....i've discovered (at least with the GHDL compiler) that the ORDER of the source files matters.... by (redundantly!!!) declaring
component
interfaces inneorv32_package.vhd
, we can simply list the core source files alphabetically.... this "works" becauseneorv32_package.vhd
has acomponent
declaration that matches someentity
declaration (where the latter is being instantiated); andneorv32_package.vhd
is seen before any of theneorv32_<entity>.vhd
sources....were we to …