VHDLDS
A VHDL Dependency Sort Program
web: www.ht-lab.com
Last Updated: 25-July-2007
VHDL require files to be compiled in the right order, for example entities or configurations must be compiled before an architecture that references them. Similarly packages must be compiled before they are reference by the use clause. Most tools such as Modelsim and HDL Designer will sort out the compile order automatically. However, there are still some EDA tools which doesn't do this for you. This utility might help in these cases. VHDLDS can also aid in creating simple scripts.
VHDLDS is the GUI front-end (made with the excellent Revolution) to the VHDLSORT program. You load a bunch of VHDL files and VHDLSORT will produce a sorted dependency output list. You can also specify pre and post strings which are added to the produced output file list.

- License Agreement
- Download Software
- Installation
- VHDLDS Usage
- Limitations
- VHDLSORT Command-line options
1. License Agreement
VHDLDS and VHDLSORT are FREEWARE.
This license agreement is a legal agreement between you (either an individual
or a single entity) and the author of this software package. By installing or
otherwise using this software you agree to be bound by this agreement. If you
do not agree to the terms of this Agreement, you may not install or use this
software.
You may install and use an unlimited number of copies of this software
on your computers.
The author will not make available Technical Support for
this Software. The author may, from time to time, revise or update the Software.
In so doing, the author incurs no obligation to furnish such revision or updates
to you.
THIS SOFTWARE IS DISTRIBUTED "AS IS". NO
WARRANTY OF ANY KIND IS EXPRESSED OR IMPLIED. YOU USE VHDLDS/VHDLSORT AT YOUR
OWN RISK. THE AUTHOR WILL NOT BE LIABLE FOR DATA LOSS, DAMAGES, LOSS OF PROFITS
OR ANY OTHER KIND OF LOSS WHILE USING OR MISUSING THIS SOFTWARE.
2. Download software
- Windows Version 0.89 [zipped, 915 KByte, tested on XP]
- Linux Version
0.89 [zipped, 1073 KByte, tested on Gentoo
2.6.22]
Version 0.89 (24-May-08), some minor VHDL93 fixes.
Version 0.85 (31-Jan-06), fixed generate state and attributes
Version 0.82 (13-Mar-05), re-generated the GUI using the latest
Revolution and it now also looks OK on XP. If you are after a easy
to use GUI builder I would certainly recommend you check out Revolution.
Version 0.82 (12-Mar-05), Several fixes mainly for VHDL93, I no
longer have access to Revolution so the GUI looks dated and is actually
not that user friendly. I would recommend you use the command line version
only.
Version 0.7 (05-Nov-04), Associations fixed for function
and procedure calls.
Version 0.6 (06-Jul-04), Line bug not fixed, show message
"missing CR/LF" instead, source files must end with a CR/LF (Newline).
Version
0.5 (22-Apr-04), file 93 support added
Version 0.4 (11-Feb-04), configurations
added
Version 0.3 (30-Nov-03) fixes a problem with the filename case,
in the previous version all filenames were downcased by mistake. I have
also noticed that VHDLDS looks pretty horrible on XP!
3. Installation
Unzip the file to a suitable directory. VHDLSORT must be in the search path
in order for VHDLDS (the GUI) to find it.
4. VHDLDS Usage
I don't believe I have to explain how to use the GUI :-)
There are only a few point to note. You
can highlight multiple lines and then click the Add or Remove
button. You can also double click in either window to add or remove files. You
can also remove file(s) by highlighting the filenames and then pressing the
DEL key. VHDLDS will produce relative path if you set the project directory
first before adding any files. If you add the files first and then select the
project directory you end up with absolute path names. After a successful sort
VHDLDS will write a project file under the name of VHDLSORT.INI This is just
a textfile which you can edit by hand. If you want VHDLDS to start with the
previous settings or some other settings you need to copy the file to the directory
you start VHDLDS from.
5. Limitations
- VHDLSORT does not support configurations, although the parser no longer complains about them the sorted file list will not be correct.
- You can only have one architecture per file.
- Only synthesizable VHDL87/93 constructs are supported although the parser will handle most testbench files.
- Circular dependency in packages are not correctly resolved.
- "for all" clauses are ignored.
6. VHDLSORT Command-Line options
NAME
vhdlsort - VHDL Dependency sort program
SYNOPSIS
vhdlsort [-q] [-f filename] [-o filename] [-b "string"] [-a "string"]
DESCRIPTION
vhdlsort is a simple VHDL filelist dependency sort program. The input is a VHDL filelist and the output is a sorted filelist with resolved dependency. vhdlsort can handle most VHDL87 and 93 language constructs except for configurations, "for all" clauses and circular dependency in packages.
OPTIONS
|
-q |
quiet mode (specify first, default: OFF) |
|
-f <filelist> |
unsorted input file list |
|
-o <filename> |
sorted output filelist (default: a.out.f) |
|
-b <"string"> |
optional pre-string. The string must be delimited by " or ' character |
|
-a <"string"> |
optional post-string. The string must be delimited by " or ' character |
EXAMPLES
1. Create a sorted filelist, the files are specified in files.f, the
output is written to sorted.f
vhdlsort
-f files.f -o sorted.f
|
Unsorted input filelist files.f |
Sorted output filelist sorted.f |
|
examples/cordic/addsub.vhd |
examples/cordic/addsub.vhd |
2. Create a compile batch file for DOS/Windows/Cygwin
vhdlsort
-f files.f -o compile.bat -b "vcom -quiet -93 "
|
Unsorted input filelist files.f |
Sorted output filelist compile.bat |
|
examples/cordic/addsub.vhd |
vcom -quiet -93 examples/cordic/addsub.vhd |
3. Create a Precision Synthesis Add_Files script
vhdlsort
-f files.f -o add_files.tcl -b "add_input_file {"
-a "}"
|
Unsorted input filelist files.f |
Sorted output filelist add_files.tcl |
|
examples/cordic/addsub.vhd |
add_input_file {examples/cordic/addsub.vhd} |
