code-guide.txt from CQual at Krugle
Show code-guide.txt syntax highlighted
A guide to the cqual source code
Jeffrey S. Foster
Last update: March 13, 2001
SOURCE CODE OVERVIEW
--------------------
The source code can conceptually be divided into three modules: A C
Front-End, written by David Gay (dgay@cs) and available separately as
a stand-alone tool; a constraint solver for type qualifier constraints
(i.e., atomic subtyping constraints); and an analysis tool that
uses the C front-end and qualifier constraint solver to do type
qualifier inference for C.
+-----------------------+
| Source code analysis/ |
| Constraint generation |
+-----------------------+
/ \
/ \
+-------------------+ +----------------+
| Type Qualifier | | C Front-End |
| Constraint Solver | +----------------+
+-------------------+
These module boundaries are not entirely clean, in the sense that each
module contains explicit support for the other modules (e.g., the
constraint solver allows several pieces of extra information to be
stored along with the constant qualifiers, and the C front-end has
been extended to understand user-defined type qualifiers).
However, the system has been designed so that each piece can be used
in isolation. For example, the type qualifier constraint solver can
be pulled out and used with other front-ends. The iquals type
qualifier constraint solver is one example.
C FRONT-END
-----------
The C front-end consists of the following files:
AST.c
AST.h
AST_defs.c
AST_defs.h
AST_parent.c
AST_print.c
AST_types.h
AST_utils.c
AST_utils.h
build-basics.el
build-parent.el
build-print.el
build-types.el
c-gpref.h
c-lex.c
c-lex.h
c-parse.gperf
c-parse.h
c-parse.tab.c
c-parse.tab.h
c-parse.y
callcc1.c
callcc1.h
config.h
constants.c
constant.h
cstring.h
decls.h
env.c
env.h
errors.c
errors.h
expr.c
expr.h
flags.h
input.c
input.h
location.h
nodetypes.def
parser.h
qualifiers.h
semantics.c
semantics.h
stmt.c
stmt.h
toplev.c
types.c
types.h
unparse.c
unparse.h
UTILITIES
---------
bool.h
buffer.c
buffer.h
dd_list.c
dd_list.h
hash.c
hash.h
hash_info.c
hash_info.h
linkage.h
regions.c
regions.h
set.c
set.h
util.c
util.h
utils.c
utils.h
QUALIFIER CONSTRAINT SOLVER
---------------------------
lattice
lattice-lex.c
lattice-parse.c
lattice-parse.h
lattice-parse.l
lattice-parse.y
quals.c
quals.h
IQUALS
------
iquals-lex.c
iquals.l
iquals.tab.c
iquals.tab.h
iquals.y
ANALYSIS/CONSTRAINT GENERATION
------------------------------
analyze.c
analyze.h
cqual.h
dqtype.h
main.c
prelude.i
proto.i
qtype.c
qtype.h
store.c
store.h
PAM INTERFACE
-------------
color.h
pam.c
pam.h
See more files for this project here