Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Mirror of GHDL SVN with fixes
Ada VHDL C Other
Branch: master
Pull request Compare This branch is 1 commit behind davewebb8211:master.

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
doc
libraries
ortho
psl
translate
xtools
.gdbinit
COPYING
README
back_end.adb
back_end.ads
bug.adb
bug.ads
canon.adb
canon.ads
canon_psl.adb
canon_psl.ads
configuration.adb
configuration.ads
disp_tree.adb
disp_tree.ads
disp_vhdl.adb
disp_vhdl.ads
errorout.adb
errorout.ads
evaluation.adb
evaluation.ads
files_map.adb
files_map.ads
flags.adb
flags.ads
ieee-std_logic_1164.adb
ieee-std_logic_1164.ads
ieee-vital_timing.adb
ieee-vital_timing.ads
ieee.ads
iir_chain_handling.adb
iir_chain_handling.ads
iir_chains.adb
iir_chains.ads
iirs.adb
iirs.adb.in
iirs.ads
iirs_utils.adb
iirs_utils.ads
iirs_walk.adb
iirs_walk.ads
libraries.adb
libraries.ads
lists.adb
lists.ads
name_table.adb
name_table.ads
nodes.adb
nodes.ads
options.adb
options.ads
parse.adb
parse.ads
parse_psl.adb
parse_psl.ads
post_sems.adb
post_sems.ads
psl-errors.ads
scan-scan_literal.adb
scan.adb
scan.ads
sem.adb
sem.ads
sem_assocs.adb
sem_assocs.ads
sem_decls.adb
sem_decls.ads
sem_expr.adb
sem_expr.ads
sem_names.adb
sem_names.ads
sem_psl.adb
sem_psl.ads
sem_scopes.adb
sem_scopes.ads
sem_specs.adb
sem_specs.ads
sem_stmts.adb
sem_stmts.ads
sem_types.adb
sem_types.ads
std_names.adb
std_names.ads
std_package.adb
std_package.ads
str_table.adb
str_table.ads
tokens.adb
tokens.ads
types.ads
version.ads
xrefs.adb
xrefs.ads

README

This directory contains the sources of GHDL, the VHDL simulator.

GHDL is free software.  See the file COPYING for copying permission.
The manuals, and some of the runtime libraries, are under different
terms; see the individual source files for details.

### Creating a source tar. ###
##############################

GHDL requires GCC to be compiled.  The exact version of GCC is defined in
./translate/gcc/dist.sh, in the GCCVERSION= line.  Do not try to change the
version, this may not compile or create a buggy compiler.

The GHDL sources provided on http://ghdl.free.fr do not exactly match the
files hierarchy here.  The later are used to directly build a compiler and
follow what GCC expect, while the former are used to do development and
are more logically organized.

Use the ./translate/gcc/dist.sh script to create sources to be included in GCC:
$ cd translate/gcc
$ ./dist.sh sources
# This generates a ghdl-VERSION.tar.bz2 file.


### Compiling for development.  ###
###################################

These steps can make GHDL development hard.  You can avoid to compile GCC
everytime.  To do this, edit ortho/gcc/Makefile and set two variables:
AGCC_GCCSRC_DIR is the GCC sources directory, while AGCC_GCCOBJ_DIR is where
you have compiled GCC+GHDL once.  Then, you can compile:
the GHDL back-end (ghdl1) in ./translate:
 $ make BE=gcc
the GHDL driver in ./translate/ghdldrv:
 $ make ghdl_gcc
the VHDL libraries (in ./translate/ghdldrv; you may need to slighly edit
 Makefile to change the compiler):
 $ ln -sf ghdl_gcc ghdl
 $ make install.all
and the GHDL run-time (GRT) in ./translate/grt:
 $ make
To use this GRT, you must create two links in translate/lib:
 $ ln -s ../grt/grt.lst .
 $ ln -s ../grt/libgrt.a .

Once this is done, you can use the ghdl_gcc from translate/ghdldrv.

### Compiling and using the debug back-end.  ###
################################################

Debugging GHDL outputs can be very difficuly with the GCC back-end, since you
don't see the high level code generated by GHDL.  To help debugging the
translator, I have written a debug back-end.  This back-end is used instead of
the GCC back-end and displays pseudo-code (as well as declarations).  This
pseudo-code can be then compiled with a reader.
To compile it, go to ./translate:
 $ make BE=debug
This creates a ghdl1-debug.  Then go to ./ortho/oread and compile the reader:
 $ make BE=gcc
You can now use this chain by adding the '--post' option to the ghdl driver:
 $ ghdl_gcc -a --post my_file.vhdl
This creates an intermediate file my_file.on, which is then compiled by
 oread-gcc.

Tristan.


Something went wrong with that request. Please try again.