* configure.ac, Makefile.am, src/Makefile.am, doc/Makefile.am,

examples/Makefile.am, examples/Makefile.def,
examples/adder/Makefile.am, examples/calculator/Makefile.am,
examples/cmilner/Makefile.am, examples/fdd/Makefile.am,
examples/internal/Makefile.am, examples/milner/Makefile.am,
examples/money/Makefile.am, examples/queen/Makefile.am,
examples/solitar/Makefile.am, m4/debug.m4, m4/gccwarns.m4,
ChangeLog, INSTALL: New files.
* config, makefile, src/makefile, doc/makefile,
examples/adder/makefile, examples/calculator/makefile
examples/cmilner/makefile, examples/fdd/makefile,
examples/internal/makefile, examples/milner/makefile,
examples/money/makefile, examples/queen/makefile,
examples/solitare/makefile : Delete.
* examples/adder/adder.cxx, examples/fdd/statespace.cxx,
examples/internal/bddtest.cxx, examples/milner/milner.cxx,
examples/money/money.cxx, examples/queen/queen.cxx,
examples/solitare/solitare.cxx: Include iostream.
* examples/calculator/parser.y: Rename as ...
* examples/calculator/parser.yxx: ... this.  Remove spurious
comas in %token, %right, and %left arguments.
* examples/calculator/parser.h: Rename as ...
* examples/calculator/parser_.h: ... this, because the bison
rule with output parser.h (not tokens.h) from parser.y.
* examples/calculator/lexer.l: Rename as ...
* examples/calculator/lexer.lxx: ... this.  Include parser.h
instead of tokens.h.
* examples/calculator/slist.h
(voidSList::voisSListElem, SList::ite): Fix friend usage.
* src/kernel.h (DEFAULT_CLOCK): Default to 60 if not already
defined.
* README: Update build instruction, and file listing.
This commit is contained in:
Alexandre Duret-Lutz 2003-05-05 13:44:49 +00:00
parent cf5dd46350
commit 605dce2aac
79 changed files with 768 additions and 669 deletions

8
buddy/.cvsignore Normal file
View file

@ -0,0 +1,8 @@
Makefile.in
Makefile
aclocal.m4
configure
tools
config.log
config.status
libtool

35
buddy/ChangeLog Normal file
View file

@ -0,0 +1,35 @@
2003-05-05 Alexandre Duret-Lutz <aduret@src.lip6.fr>
* configure.ac, Makefile.am, src/Makefile.am, doc/Makefile.am,
examples/Makefile.am, examples/Makefile.def,
examples/adder/Makefile.am, examples/calculator/Makefile.am,
examples/cmilner/Makefile.am, examples/fdd/Makefile.am,
examples/internal/Makefile.am, examples/milner/Makefile.am,
examples/money/Makefile.am, examples/queen/Makefile.am,
examples/solitar/Makefile.am, m4/debug.m4, m4/gccwarns.m4,
ChangeLog, INSTALL: New files.
* config, makefile, src/makefile, doc/makefile,
examples/adder/makefile, examples/calculator/makefile
examples/cmilner/makefile, examples/fdd/makefile,
examples/internal/makefile, examples/milner/makefile,
examples/money/makefile, examples/queen/makefile,
examples/solitare/makefile : Delete.
* examples/adder/adder.cxx, examples/fdd/statespace.cxx,
examples/internal/bddtest.cxx, examples/milner/milner.cxx,
examples/money/money.cxx, examples/queen/queen.cxx,
examples/solitare/solitare.cxx: Include iostream.
* examples/calculator/parser.y: Rename as ...
* examples/calculator/parser.yxx: ... this. Remove spurious
comas in %token, %right, and %left arguments.
* examples/calculator/parser.h: Rename as ...
* examples/calculator/parser_.h: ... this, because the bison
rule with output parser.h (not tokens.h) from parser.y.
* examples/calculator/lexer.l: Rename as ...
* examples/calculator/lexer.lxx: ... this. Include parser.h
instead of tokens.h.
* examples/calculator/slist.h
(voidSList::voisSListElem, SList::ite): Fix friend usage.
* src/kernel.h (DEFAULT_CLOCK): Default to 60 if not already
defined.
* README: Update build instruction, and file listing.

229
buddy/INSTALL Normal file
View file

@ -0,0 +1,229 @@
Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002 Free Software
Foundation, Inc.
This file is free documentation; the Free Software Foundation gives
unlimited permission to copy, distribute and modify it.
Basic Installation
==================
These are generic installation instructions.
The `configure' shell script attempts to guess correct values for
various system-dependent variables used during compilation. It uses
those values to create a `Makefile' in each directory of the package.
It may also create one or more `.h' files containing system-dependent
definitions. Finally, it creates a shell script `config.status' that
you can run in the future to recreate the current configuration, and a
file `config.log' containing compiler output (useful mainly for
debugging `configure').
It can also use an optional file (typically called `config.cache'
and enabled with `--cache-file=config.cache' or simply `-C') that saves
the results of its tests to speed up reconfiguring. (Caching is
disabled by default to prevent problems with accidental use of stale
cache files.)
If you need to do unusual things to compile the package, please try
to figure out how `configure' could check whether to do them, and mail
diffs or instructions to the address given in the `README' so they can
be considered for the next release. If you are using the cache, and at
some point `config.cache' contains results you don't want to keep, you
may remove or edit it.
The file `configure.ac' (or `configure.in') is used to create
`configure' by a program called `autoconf'. You only need
`configure.ac' if you want to change it or regenerate `configure' using
a newer version of `autoconf'.
The simplest way to compile this package is:
1. `cd' to the directory containing the package's source code and type
`./configure' to configure the package for your system. If you're
using `csh' on an old version of System V, you might need to type
`sh ./configure' instead to prevent `csh' from trying to execute
`configure' itself.
Running `configure' takes awhile. While running, it prints some
messages telling which features it is checking for.
2. Type `make' to compile the package.
3. Optionally, type `make check' to run any self-tests that come with
the package.
4. Type `make install' to install the programs and any data files and
documentation.
5. You can remove the program binaries and object files from the
source code directory by typing `make clean'. To also remove the
files that `configure' created (so you can compile the package for
a different kind of computer), type `make distclean'. There is
also a `make maintainer-clean' target, but that is intended mainly
for the package's developers. If you use it, you may have to get
all sorts of other programs in order to regenerate files that came
with the distribution.
Compilers and Options
=====================
Some systems require unusual options for compilation or linking that
the `configure' script does not know about. Run `./configure --help'
for details on some of the pertinent environment variables.
You can give `configure' initial values for configuration parameters
by setting variables in the command line or in the environment. Here
is an example:
./configure CC=c89 CFLAGS=-O2 LIBS=-lposix
*Note Defining Variables::, for more details.
Compiling For Multiple Architectures
====================================
You can compile the package for more than one kind of computer at the
same time, by placing the object files for each architecture in their
own directory. To do this, you must use a version of `make' that
supports the `VPATH' variable, such as GNU `make'. `cd' to the
directory where you want the object files and executables to go and run
the `configure' script. `configure' automatically checks for the
source code in the directory that `configure' is in and in `..'.
If you have to use a `make' that does not support the `VPATH'
variable, you have to compile the package for one architecture at a
time in the source code directory. After you have installed the
package for one architecture, use `make distclean' before reconfiguring
for another architecture.
Installation Names
==================
By default, `make install' will install the package's files in
`/usr/local/bin', `/usr/local/man', etc. You can specify an
installation prefix other than `/usr/local' by giving `configure' the
option `--prefix=PATH'.
You can specify separate installation prefixes for
architecture-specific files and architecture-independent files. If you
give `configure' the option `--exec-prefix=PATH', the package will use
PATH as the prefix for installing programs and libraries.
Documentation and other data files will still use the regular prefix.
In addition, if you use an unusual directory layout you can give
options like `--bindir=PATH' to specify different values for particular
kinds of files. Run `configure --help' for a list of the directories
you can set and what kinds of files go in them.
If the package supports it, you can cause programs to be installed
with an extra prefix or suffix on their names by giving `configure' the
option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
Optional Features
=================
Some packages pay attention to `--enable-FEATURE' options to
`configure', where FEATURE indicates an optional part of the package.
They may also pay attention to `--with-PACKAGE' options, where PACKAGE
is something like `gnu-as' or `x' (for the X Window System). The
`README' should mention any `--enable-' and `--with-' options that the
package recognizes.
For packages that use the X Window System, `configure' can usually
find the X include and library files automatically, but if it doesn't,
you can use the `configure' options `--x-includes=DIR' and
`--x-libraries=DIR' to specify their locations.
Specifying the System Type
==========================
There may be some features `configure' cannot figure out
automatically, but needs to determine by the type of machine the package
will run on. Usually, assuming the package is built to be run on the
_same_ architectures, `configure' can figure that out, but if it prints
a message saying it cannot guess the machine type, give it the
`--build=TYPE' option. TYPE can either be a short name for the system
type, such as `sun4', or a canonical name which has the form:
CPU-COMPANY-SYSTEM
where SYSTEM can have one of these forms:
OS KERNEL-OS
See the file `config.sub' for the possible values of each field. If
`config.sub' isn't included in this package, then this package doesn't
need to know the machine type.
If you are _building_ compiler tools for cross-compiling, you should
use the `--target=TYPE' option to select the type of system they will
produce code for.
If you want to _use_ a cross compiler, that generates code for a
platform different from the build platform, you should specify the
"host" platform (i.e., that on which the generated programs will
eventually be run) with `--host=TYPE'.
Sharing Defaults
================
If you want to set default values for `configure' scripts to share,
you can create a site shell script called `config.site' that gives
default values for variables like `CC', `cache_file', and `prefix'.
`configure' looks for `PREFIX/share/config.site' if it exists, then
`PREFIX/etc/config.site' if it exists. Or, you can set the
`CONFIG_SITE' environment variable to the location of the site script.
A warning: not all `configure' scripts look for a site script.
Defining Variables
==================
Variables not defined in a site shell script can be set in the
environment passed to `configure'. However, some packages may run
configure again during the build, and the customized values of these
variables may be lost. In order to avoid this problem, you should set
them in the `configure' command line, using `VAR=value'. For example:
./configure CC=/usr/local2/bin/gcc
will cause the specified gcc to be used as the C compiler (unless it is
overridden in the site shell script).
`configure' Invocation
======================
`configure' recognizes the following options to control how it
operates.
`--help'
`-h'
Print a summary of the options to `configure', and exit.
`--version'
`-V'
Print the version of Autoconf used to generate the `configure'
script, and exit.
`--cache-file=FILE'
Enable the cache: use and save the results of the tests in FILE,
traditionally `config.cache'. FILE defaults to `/dev/null' to
disable caching.
`--config-cache'
`-C'
Alias for `--cache-file=config.cache'.
`--quiet'
`--silent'
`-q'
Do not print messages saying which checks are being made. To
suppress all normal output, redirect it to `/dev/null' (any error
messages will still be shown).
`--srcdir=DIR'
Look for the package's source code in directory DIR. Usually
`configure' can determine that directory automatically.
`configure' also accepts some other, not widely useful, options. Run
`configure --help' for more details.

5
buddy/Makefile.am Normal file
View file

@ -0,0 +1,5 @@
ACLOCAL_AMFLAGS = -I m4
SUBDIRS = src examples doc
EXTRA_DIST = CHANGES m4/debug.m4 m4/gccwarns.m4

View file

@ -1,7 +1,7 @@
==========================================================================
*** BuDDy ***
Binary Decision Diagrams
Library Package v2.2
Library Package v2.2a
--------------------------------------------------------------------------
Copyright (C) 1996-2002 by Jorn Lind-Nielsen
All rights reserved
@ -45,15 +45,38 @@
--- INSTALLING ------------------------------------------------------
---------------------------------------------------------------------
2) Edit the file "config" to specify your compiler options and
where the package is to be installed.
The following commands should build and install the library.
3) type "make" to make the binary.
./configure
make
make install
4) type "make install" to copy the BDD files to their appropriate
directories.
`./configure' accepts many arguments to tune your installation.
The following options are noteworthy:
5) type "make examples" to make the examples
--includedir=/somewhere/include
Specify where header files will be installed.
--libdir=/somewhere/lib
Specify where libraries will be installed.
--disable-shared
Do not build the shared library for BuDDy.
--disable-static
Do not build the static library for BuDDy.
--enable-swap-count
Count number of fundamental variable swaps (for debugging)
--enable-cache-stats
Gather statistical information about operator and unique node
caching (for debugging)
Run `./configure --help' for a complete listing, and see
the INSTALL file for generic intrustions.
Run `make check' to build the examples.
---------------------------------------------------------------------
@ -91,7 +114,8 @@ examples: Example files
doc: Documentation.
buddy.ps: Package documentation.
bddnotes.ps: BDD introduction notes.
tools: Tools used during the build.
m4: A couple of macros used to build ./configure.
---------------------------------------------------------------------
--- FEEDBACK --------------------------------------------------------

View file

@ -1,46 +0,0 @@
# ==============================================================
# Makefile for the BuDDy package
# - Edit the lines below to configure
# ==============================================================
# --- Your compiler flags
CFLAGS = -g -ansi -Wmissing-prototypes -Wall
# --- Where to install the library (directory, no trailing slash)
LIBDIR = /usr/local/lib
# --- Where to install the include file (directory, no trailing slash)
INCDIR = /usr/local/include
# --- Your C compiler
CC = gcc
# --- Your C++ compiler
CPP = g++
# Some machines are missing "CLOCKS_PER_SEC". Please define a default value
# If you do not know this, then leave it as it is.
CLOCK=60
CLOCKFLAG = -DDEFAULT_CLOCK=$(CLOCK)
# Debugging and statistical flags. Possible values are:
# -DSWAPCOUNT : Count number of fundamental variable swaps
# -DCACHESTATS : Gather statistical information about operator and
# unique node caching
DEBUGFLAGS =
# Some of the BuDDy library needs 64 bit arithmetics.
# With gnu C++, Microsoft C++ and KAI C++ this is part of the
# language and used by BuDDy. With other compilers BuDDy need
# to implement the math it self -- which is a bit slower. If
# you now of a 64 bit unsigned integer type on your platform
# then define that in the BUDDYUINT64 variable. Example:
# BUDDYUINT64 = -DBUDDYUINT64="long long"
# --------------------------------------------------------------
# Do not touch
# --------------------------------------------------------------
DFLAGS = $(CLOCKFLAG) $(DEBUGFLAGS) $(BUDDYUINT64)

33
buddy/configure.ac Normal file
View file

@ -0,0 +1,33 @@
AC_PREREQ([2.57])
AC_INIT([buddy], [2.2a])
AC_CONFIG_AUX_DIR([tools])
AM_INIT_AUTOMAKE([foreign nostdinc no-define 1.7.3])
AC_PROG_CC
AM_PROG_LEX
AC_PROG_YACC
AC_PROG_CXX
AC_PROG_LIBTOOL
buddy_DEBUG_FLAGS
AC_CONFIG_FILES([
Makefile
src/Makefile
doc/Makefile
examples/Makefile
examples/adder/Makefile
examples/calculator/Makefile
examples/cmilner/Makefile
examples/fdd/Makefile
examples/internal/Makefile
examples/milner/Makefile
examples/money/Makefile
examples/queen/Makefile
examples/solitare/Makefile
])
AC_OUTPUT

2
buddy/doc/.cvsignore Normal file
View file

@ -0,0 +1,2 @@
Makefile.in
Makefile

1
buddy/doc/Makefile.am Normal file
View file

@ -0,0 +1 @@
EXTRA_DIST = bddnotes.ps buddy.ps tech.txt

View file

@ -1 +0,0 @@
clean:

View file

@ -0,0 +1,2 @@
Makefile.in
Makefile

View file

@ -0,0 +1,11 @@
SUBDIRS = \
adder \
calculator \
cmilner \
fdd \
internal \
milner \
money \
queen \
solitare

View file

@ -0,0 +1,2 @@
AM_CPPFLAGS = -I$(top_srcdir)/src
LDADD = $(top_builddir)/src/libbdd.la

View file

@ -0,0 +1,4 @@
Makefile.in
Makefile
adder
.deps

View file

@ -0,0 +1,3 @@
include ../Makefile.def
check_PROGRAMS = adder
adder_SOURCES = adder.cxx

View file

@ -7,8 +7,11 @@
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <iostream>
#include "bdd.h"
using namespace std;
int N;
bdd *ainp;

View file

@ -1,36 +0,0 @@
# --------------------------------
# Makefile for adder test example
# --------------------------------
# --- Compiler flags
CFLAGS = -g -pedantic -Wall -ansi -L../../src -I../../src
# --- C++ compiler
CPP = g++
# --- C compiler
CC = gcc
# --- Do not touch ---
.SUFFIXES: .cxx .c
.cxx.o:
$(CPP) $(CFLAGS) -c $<
.c.o:
$(CC) $(CFLAGS) -c $<
adder: adder.o bddlib
$(CPP) $(CFLAGS) adder.o -o adder -lbdd -lm
bddlib:
cd ../..; make
clean:
rm -f *~
rm -f *.o
rm -f adder
adder.o: ../../src/bdd.h

View file

@ -0,0 +1,6 @@
Makefile.in
Makefile
lexer.cxx
parser.cxx
parser.h
.deps

View file

@ -0,0 +1,25 @@
include ../Makefile.def
EXTRA_DIST = \
readme \
example.cal \
examples/c432.cal \
examples/c499.cal \
examples/c1355.cal \
examples/c1908.cal \
examples/c2670.cal \
examples/c3540.cal \
examples/readme
AM_YFLAGS = -d
BUILT_SOURCES = parser.h
check_PROGRAMS = bddcalc
bddcalc_SOURCES = \
hashtbl.h \
hashtbl.cxx \
lexer.lxx \
parser.yxx \
parser_.h \
slist.h

View file

@ -1,5 +1,5 @@
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/examples/calculator/Attic/hashtbl.cxx,v 1.1 2003/05/05 10:57:55 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/examples/calculator/Attic/hashtbl.cxx,v 1.2 2003/05/05 13:44:53 aduret Exp $
FILE: hashtbl.cc
DESCR: Compiler hash table
AUTH: Jorn Lind

View file

@ -1,5 +1,5 @@
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/examples/calculator/Attic/hashtbl.h,v 1.1 2003/05/05 10:57:55 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/examples/calculator/Attic/hashtbl.h,v 1.2 2003/05/05 13:44:54 aduret Exp $
FILE: hashtbl.h
DESCR: Compiler hashtable
AUTH: Jorn Lind

View file

@ -7,8 +7,8 @@
%{
#include <string.h>
#include <stdlib.h>
#include "parser_.h"
#include "parser.h"
#include "tokens.h"
%}

View file

@ -1,48 +0,0 @@
# ---------------------------
# Makefile for BDD calculator
# ---------------------------
all: bddcalc
# --- Compiler flags
CFLAGS = -O3 -pedantic -Wall -ansi -L../../src -I../../src
# --- C++ compiler
CPP = g++
# --- C compiler
CC = gcc
# --- You may need to change these according to your flex and bison versions
parser.cxx: parser.h parser.y
bison -d -o parser.cxx parser.y
mv parser.cxx.h tokens.h
lexer.cxx: tokens.h parser.h lexer.l
flex -olexer.cxx lexer.l
# --- Do not touch ---
.SUFFIXES: .cxx .c
.cxx.o:
$(CPP) $(CFLAGS) -c $<
.c.o:
$(CC) $(CFLAGS) -c $<
bddcalc: parser.o lexer.o hashtbl.o bddlib
$(CPP) $(CFLAGS) parser.o lexer.o hashtbl.o -o bddcalc -lbdd -lm
bddlib:
cd ../..; make
clean:
rm -f *~ examples/*~
rm -f *.o
rm -f bddcalc parser.cxx lexer.cxx
# --- Needed for the author's Cygwin compiler
export BISONLIB=/cygnus/cygwin-b20/share/

View file

@ -1,44 +1,118 @@
/*************************************************************************
FILE: parser.h
DESCR: parser defs. for BDD calculator
AUTH: Jorn Lind
DATE: (C) may 1999
*************************************************************************/
/* A Bison parser, made by GNU Bison 1.875b. */
#ifndef _PARSER_H
#define _PARSER_H
/* Skeleton parser for Yacc-like parsing with Bison,
Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
#include <stdio.h>
#include "bdd.h"
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2, or (at your option)
any later version.
#define MAXIDLEN 32 /* Max. number of allowed characters in an identifier */
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
struct token /* BISON token data */
{
char id[MAXIDLEN+1];
char *str;
int ival;
bdd *bval;
};
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
#define YYSTYPE token
#define YY_SKIP_YYWRAP
#define YY_NO_UNPUT
#define yywrap() (1)
/* As a special exception, when this file is copied by Bison into a
Bison output file, you may use that output file without restriction.
This special exception was added by the Free Software Foundation
in version 1.24 of Bison. */
extern YYSTYPE yylval; /* Declare for flex user */
extern void yyerror(char *,...); /* Declare for flex and bison */
extern FILE *yyin;
extern int yylex(void); /* Declare for bison */
extern int yyparse(void); /* Declare for bison user */
extern int linenum; /* Declare for error handler */
/* Tokens. */
#ifndef YYTOKENTYPE
# define YYTOKENTYPE
/* Put the tokens into the symbol table, so that GDB and other debuggers
know about them. */
enum yytokentype {
T_id = 258,
T_str = 259,
T_intval = 260,
T_true = 261,
T_false = 262,
T_initial = 263,
T_inputs = 264,
T_actions = 265,
T_size = 266,
T_dumpdot = 267,
T_autoreorder = 268,
T_reorder = 269,
T_win2 = 270,
T_win2ite = 271,
T_sift = 272,
T_siftite = 273,
T_none = 274,
T_cache = 275,
T_tautology = 276,
T_print = 277,
T_lpar = 278,
T_rpar = 279,
T_equal = 280,
T_semi = 281,
T_dot = 282,
T_forall = 283,
T_exist = 284,
T_biimp = 285,
T_imp = 286,
T_nor = 287,
T_or = 288,
T_xor = 289,
T_and = 290,
T_nand = 291,
T_not = 292
};
#endif
#define T_id 258
#define T_str 259
#define T_intval 260
#define T_true 261
#define T_false 262
#define T_initial 263
#define T_inputs 264
#define T_actions 265
#define T_size 266
#define T_dumpdot 267
#define T_autoreorder 268
#define T_reorder 269
#define T_win2 270
#define T_win2ite 271
#define T_sift 272
#define T_siftite 273
#define T_none 274
#define T_cache 275
#define T_tautology 276
#define T_print 277
#define T_lpar 278
#define T_rpar 279
#define T_equal 280
#define T_semi 281
#define T_dot 282
#define T_forall 283
#define T_exist 284
#define T_biimp 285
#define T_imp 286
#define T_nor 287
#define T_or 288
#define T_xor 289
#define T_and 290
#define T_nand 291
#define T_not 292
#if ! defined (YYSTYPE) && ! defined (YYSTYPE_IS_DECLARED)
typedef int YYSTYPE;
# define yystype YYSTYPE /* obsolescent; will be withdrawn */
# define YYSTYPE_IS_DECLARED 1
# define YYSTYPE_IS_TRIVIAL 1
#endif
extern YYSTYPE yylval;
/* Use this instead of strdup() to avoid malloc() */
inline char *sdup(const char *s)
{
return strcpy(new char[strlen(s)+1], s);
}
#endif /* _PARSER_H */
/* EOF */

View file

@ -8,13 +8,15 @@
%{
#include <string.h>
#include <stdarg.h>
#include <fstream.h>
#include <fstream>
#include <getopt.h>
#define IMPLEMENTSLIST /* Special for list template handling */
#include "slist.h"
#include "hashtbl.h"
#include "parser.h"
#include "parser_.h"
using namespace std;
/* Definitions for storing and caching of identifiers */
#define inputTag 0
#define exprTag 1
@ -64,23 +66,23 @@ void actPrint(token *id);
Token definitions
*************************************************************************/
%token T_id, T_str, T_intval, T_true, T_false
%token T_id T_str T_intval T_true T_false
%token T_initial, T_inputs, T_actions
%token T_size, T_dumpdot
%token T_autoreorder, T_reorder, T_win2, T_win2ite, T_sift, T_siftite, T_none
%token T_cache, T_tautology, T_print
%token T_initial T_inputs T_actions
%token T_size T_dumpdot
%token T_autoreorder T_reorder T_win2 T_win2ite T_sift T_siftite T_none
%token T_cache T_tautology T_print
%token T_lpar, T_rpar
%token T_lpar T_rpar
%token T_equal
%token T_semi, T_dot
%token T_semi T_dot
%right T_exist, T_forall, T_dot
%right T_exist T_forall T_dot
%left T_biimp
%left T_imp
%left T_or, T_nor
%left T_or T_nor
%left T_xor
%left T_nand, T_and
%left T_nand T_and
%right T_not
/*************************************************************************

View file

@ -0,0 +1,44 @@
/*************************************************************************
FILE: parser.h
DESCR: parser defs. for BDD calculator
AUTH: Jorn Lind
DATE: (C) may 1999
*************************************************************************/
#ifndef _PARSER_H
#define _PARSER_H
#include <stdio.h>
#include "bdd.h"
#define MAXIDLEN 32 /* Max. number of allowed characters in an identifier */
struct token /* BISON token data */
{
char id[MAXIDLEN+1];
char *str;
int ival;
bdd *bval;
};
#define YYSTYPE token
#define YY_SKIP_YYWRAP
#define YY_NO_UNPUT
#define yywrap() (1)
extern YYSTYPE yylval; /* Declare for flex user */
extern void yyerror(char *,...); /* Declare for flex and bison */
extern FILE *yyin;
extern int yylex(void); /* Declare for bison */
extern int yyparse(void); /* Declare for bison user */
extern int linenum; /* Declare for error handler */
/* Use this instead of strdup() to avoid malloc() */
inline char *sdup(const char *s)
{
return strcpy(new char[strlen(s)+1], s);
}
#endif /* _PARSER_H */
/* EOF */

View file

@ -1,5 +1,5 @@
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/examples/calculator/Attic/slist.h,v 1.1 2003/05/05 10:57:55 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/examples/calculator/Attic/slist.h,v 1.2 2003/05/05 13:44:55 aduret Exp $
FILE: slist.h
DESCR: Single linked list
AUTH: Jorn Lind
@ -28,7 +28,7 @@ protected:
private:
voidSListElem(void *d) { data=d; next=NULL; }
friend voidSList;
friend class voidSList;
};
public:
@ -169,7 +169,7 @@ public:
int operator==(ite x) { return x.next==next; }
private:
voidSListElem *next;
friend SList<T>;
friend class SList<T>;
};
~SList(void) { for (ite x=first() ; x.more() ; x++) delete &(*x); }

View file

@ -1,41 +0,0 @@
#ifndef YYSTYPE
#define YYSTYPE int
#endif
#define T_id 257
#define T_str 258
#define T_intval 259
#define T_true 260
#define T_false 261
#define T_initial 262
#define T_inputs 263
#define T_actions 264
#define T_size 265
#define T_dumpdot 266
#define T_autoreorder 267
#define T_reorder 268
#define T_win2 269
#define T_win2ite 270
#define T_sift 271
#define T_siftite 272
#define T_none 273
#define T_cache 274
#define T_tautology 275
#define T_print 276
#define T_lpar 277
#define T_rpar 278
#define T_equal 279
#define T_semi 280
#define T_dot 281
#define T_exist 282
#define T_forall 283
#define T_biimp 284
#define T_imp 285
#define T_or 286
#define T_nor 287
#define T_xor 288
#define T_nand 289
#define T_and 290
#define T_not 291
extern YYSTYPE yylval;

View file

@ -0,0 +1,3 @@
Makefile.in
Makefile
.deps

View file

@ -0,0 +1,4 @@
include ../Makefile.def
EXTRA_DIST = readme
check_PROGRAMS = milner
milner_SOURCES = milner.c

View file

@ -1,36 +0,0 @@
# --------------------------------
# Makefile for milner test example
# --------------------------------
# --- Compiler flags
CFLAGS = -O3 -pedantic -Wall -ansi -L../../src -I../../src
# --- C++ compiler
CPP = g++
# --- C compiler
CC = gcc
# --- Do not touch ---
.SUFFIXES: .cxx .c
.cxx.o:
$(CPP) $(CFLAGS) -c $<
.c.o:
$(CC) $(CFLAGS) -c $<
milner: milner.o bddlib
$(CC) $(CFLAGS) milner.o -o milner -lbdd -lm
bddlib:
cd ../..; make
clean:
rm -f *~
rm -f *.o
rm -f milner
milner.o: ../../src/bdd.h

View file

@ -0,0 +1,3 @@
Makefile.in
Makefile
.deps

View file

@ -0,0 +1,3 @@
include ../Makefile.def
check_PROGRAMS = statespace
statespace_SOURCES = statespace.cxx

View file

@ -1,36 +0,0 @@
# --------------------------------
# Makefile for FDD test example
# --------------------------------
# --- Compiler flags
CFLAGS = -O3 -pedantic -Wall -ansi -L../../src -I../../src
# --- C++ compiler
CPP = g++
# --- C compiler
CC = gcc
# --- Do not touch ---
.SUFFIXES: .cxx .c
.cxx.o:
$(CPP) $(CFLAGS) -c $<
.c.o:
$(CC) $(CFLAGS) -c $<
statespace: statespace.o bddlib
$(CPP) $(CFLAGS) statespace.o -o statespace -lbdd -lm
bddlib:
cd ../../src; make
clean:
rm -f *~
rm -f *.o
rm -f statespace
statespace.o: ../../src/fdd.h

View file

@ -6,7 +6,9 @@
* 0 -> 1 -> 2 -> 3 -> 4 -> 5 -> -> 7 -> 0
*/
#include <iostream>
#include "fdd.h"
using namespace std;
/* Use the transition relation "transRel" to iterate through the statespace
*/

View file

@ -0,0 +1,3 @@
Makefile.in
Makefile
.deps

View file

@ -0,0 +1,3 @@
include ../Makefile.def
check_PROGRAMS = bddtest
bddtest_SOURCES = bddtest.cxx

View file

@ -1,6 +1,8 @@
#include <iomanip>
#include <stdlib.h>
#include <bdd.h>
#include <iostream>
using namespace std;
static const int varnum = 5;

View file

@ -1,38 +0,0 @@
# --------------------------------
# Makefile for internal tests
# --------------------------------
# --- Compiler flags
CFLAGS = -g -pedantic -Wall -ansi -L../../src -I../../src
# --- C++ compiler
CPP = g++
# --- C compiler
CC = gcc
# --- Do not touch ---
.SUFFIXES: .cxx .c
.cxx.o:
$(CPP) $(CFLAGS) -c $<
.c.o:
$(CC) $(CFLAGS) -c $<
bddtest: bddtest.o bddlib
$(CPP) $(CFLAGS) bddtest.o -o bddtest -lbdd -lm
bddlib:
cd ../..; make
clean:
rm -f *~
rm -f *.o
rm -f bddtest
bddtest.o: ../../src/bdd.h

View file

@ -0,0 +1,3 @@
Makefile.in
Makefile
.deps

View file

@ -0,0 +1,4 @@
include ../Makefile.def
EXTRA_DIST = readme
check_PROGRAMS = milner
milner_SOURCES = milner.cxx

View file

@ -1,36 +0,0 @@
# --------------------------------
# Makefile for milner test example
# --------------------------------
# --- Compiler flags
CFLAGS = -g -pedantic -Wall -ansi -L../../src -I../../src
# --- C++ compiler
CPP = g++
# --- C compiler
CC = gcc
# --- Do not touch ---
.SUFFIXES: .cxx .c
.cxx.o:
$(CPP) $(CFLAGS) -c $<
.c.o:
$(CC) $(CFLAGS) -c $<
milner: milner.o bddlib
$(CPP) $(CFLAGS) milner.o -o milner -lbdd -lm
bddlib:
cd ../../src; make
clean:
rm -f *~
rm -f *.o
rm -f milner
milner.o: ../../src/bdd.h

View file

@ -3,6 +3,8 @@
#include <time.h>
#include <math.h>
#include "bdd.h"
#include <iostream>
using namespace std;
int N; // Number of cyclers
bdd normvar; // Current state variables

View file

@ -0,0 +1,3 @@
Makefile.in
Makefile
.deps

View file

@ -0,0 +1,3 @@
include ../Makefile.def
check_PROGRAMS = money
money_SOURCES = money.cxx

View file

@ -1,36 +0,0 @@
# --------------------------------
# Makefile for BVEC example
# --------------------------------
# --- Compiler flags
CFLAGS = -O3 -pedantic -Wall -ansi -L../../src -I../../src
# --- C++ compiler
CPP = g++
# --- C compiler
CC = gcc
# --- Do not touch ---
.SUFFIXES: .cxx .c
.cxx.o:
$(CPP) $(CFLAGS) -c $<
.c.o:
$(CC) $(CFLAGS) -c $<
money: money.o bddlib
$(CPP) $(CFLAGS) money.o -o money -lbdd -lm
bddlib:
cd ../../src; make
clean:
rm -f *~
rm -f *.o
rm -f money
money.o: ../../src/bvec.h ../../src/fdd.h ../../src/bdd.h

View file

@ -1,4 +1,6 @@
#include "bvec.h"
#include <iostream>
using namespace std;
/* Find a solution to the send-more-money example
* The problem is to assign values for the digits s,e,n,d,m,o,r,y

View file

@ -0,0 +1,3 @@
Makefile.in
Makefile
.deps

View file

@ -0,0 +1,3 @@
include ../Makefile.def
check_PROGRAMS = queen
queen_SOURCES = queen.cxx

View file

@ -1,37 +0,0 @@
# ---------------------------------
# Makefile for N-queen test example
# ---------------------------------
# --- Compiler flags
CFLAGS = -O3 -pedantic -Wall -ansi -L../../src -I../../src
# --- C++ compiler
CPP = g++
# --- C compiler
CC = gcc
# --- Do not touch ---
.SUFFIXES: .cxx .c
.cxx.o:
$(CPP) $(CFLAGS) -c $<
.c.o:
$(CC) $(CFLAGS) -c $<
queen: queen.o bddlib
$(CPP) $(CFLAGS) queen.o -o queen -lbdd -lm
bddlib:
cd ../..; make
clean:
rm -f *~
rm -f *.o
rm -f queen
queen.o: ../../src/bdd.h

View file

@ -26,7 +26,9 @@
**************************************************************************/
#include <stdlib.h>
#include <iostream>
#include "bdd.h"
using namespace std;
int N; /* Size of the chess board */
bdd **X; /* BDD variable array */

View file

@ -0,0 +1,3 @@
Makefile.in
Makefile
.deps

View file

@ -0,0 +1,3 @@
include ../Makefile.def
check_PROGRAMS = solitare
solitare_SOURCES = solitare.cxx

View file

@ -1,36 +0,0 @@
# --------------------------------
# Makefile for solitare test example
# --------------------------------
# --- Compiler flags
CFLAGS = -O3 -pedantic -Wall -ansi -L../../src -I../../src
# --- C++ compiler
CPP = g++
# --- C compiler
CC = gcc
# --- Do not touch ---
.SUFFIXES: .cxx .c
.cxx.o:
$(CPP) $(CFLAGS) -c $<
.c.o:
$(CC) $(CFLAGS) -c $<
solitare: solitare.o bddlib
$(CPP) $(CFLAGS) solitare.o -o solitare -lbdd -lm
bddlib:
cd ../..; make
clean:
rm -f *~
rm -f *.o
rm -f solitare
milner.o: ../../src/bdd.h

View file

@ -2,7 +2,11 @@
#include <time.h>
#include <unistd.h>
#include <stdlib.h>
#include <iostream>
#include "bdd.h"
using std::cout;
using std::endl;
using std::flush;
float dummyStateNum; // Use to remove the number of states defined by the
// next-state variables

25
buddy/m4/debug.m4 Normal file
View file

@ -0,0 +1,25 @@
AC_DEFUN([buddy_DEBUG_FLAGS],
[AC_ARG_ENABLE([swap-count],
[AC_HELP_STRING([--enable-swap-count],
[Count number of fundamental variable swaps (for debugging)])])
case $enable_swap_count in
yes)
AC_DEFINE([SWAPCOUNT], 1,
[Define to 1 to count number of fundamental variable swaps
(for debugging).])
;;
esac
AC_ARG_ENABLE([cache-stats],
[AC_HELP_STRING([--enable-cache-stats],
[Gather statistical information about operator and unique node caching (for debugging)])])
case $enable_cache_stats in
yes)
AC_DEFINE([CACHESTATS], 1,
[Defube to 1 to gather statistical information about operator and unique node caching (for debugging).])
;;
esac
])

51
buddy/m4/gccwarns.m4 Normal file
View file

@ -0,0 +1,51 @@
dnl Check if the compiler supports useful warning options. There's a few that
dnl we don't use, simply because they're too noisy:
dnl
dnl -ansi (prevents declaration of functions like strdup, and because
dnl it makes warning in system headers).
dnl -Wconversion (useful in older versions of gcc, but not in gcc 2.7.x)
dnl -Wtraditional (combines too many unrelated messages, only a few useful)
dnl -Wredundant-decls (system headers make this too noisy)
dnl -pedantic
dnl -Wunreachable-code (broken, see GCC PR/7827)
dnl -Wredundant-decls (too many warnings in GLIBC's header with old GCC)
dnl
dnl A few other options have been left out because they are annoying in C++.
AC_DEFUN([CF_GCC_WARNINGS],
[if test -n "$GCC"; then
AC_CACHE_CHECK([for $GCC warning options], ac_cv_prog_gxx_warn_flags,
[
cat > conftest.$ac_ext <<EOF
#line __oline__ "configure"
int main(int argc, char *argv[[]]) { return argv[[argc-1]] == 0; }
EOF
cf_save_CFLAGS="$CFLAGS"
ac_cv_prog_gcc_warn_flags="-W -Wall"
for cf_opt in \
Waggregate-return \
Wbad-function-cast \
Wcast-align \
Winline \
Wnested-externs \
Wpointer-arith \
Wwrite-strings \
Wmissing-declarations \
Wmissing-prototypes \
Wstrict-prototypes \
Wshadow \
Wcast-qual \
do
CFLAGS="$cf_save_CFLAGS $ac_cv_prog_gcc_warn_flags -$cf_opt"
if AC_TRY_EVAL(ac_compile); then
ac_cv_prog_gcc_warn_flags="$ac_cv_prog_gcc_warn_flags -$cf_opt"
test "$cf_opt" = Wcast-qual && ac_cv_prog_gcc_warn_flags="$ac_cv_prog_gcc_warn_flags -DXTSTRINGDEFINES"
fi
done
rm -f conftest*
dnl CFLAGS="$cf_save_CFLAGS"
])
fi
dnl AC_SUBST([WARNING_CFLAGS], ["${ac_cv_prog_gcc_warn_flags}"])
])

View file

@ -1,112 +0,0 @@
# ==============================================================
# Makefile for the BuDDy package
# - Do not touch. Edit "config" instead.
# ==============================================================
include config
# --------------------------------------------------------------
# The primary targets.
# --------------------------------------------------------------
buddy:
cd src; make
docs:
cd doc; make doc
install:
cp -f src/libbdd.a $(LIBDIR)/libbdd.a
chmod 644 $(LIBDIR)/libbdd.a
cp -f src/bdd.h $(INCDIR)/bdd.h
chmod 644 $(INCDIR)/bdd.h
cp -f src/fdd.h $(INCDIR)/fdd.h
chmod 644 $(INCDIR)/fdd.h
cp -f src/bvec.h $(INCDIR)/bvec.h
chmod 644 $(INCDIR)/bvec.h
uninstall:
rm -f $(LIBDIR)/libbdd.a
rm -f $(INCDIR)/bdd.h
rm -f $(INCDIR)/fdd.h
rm -f $(INCDIR)/bvec.h
# --------------------------------------------------------------
# Housekeeping
# --------------------------------------------------------------
TARGET = buddy
VERSION = 22
RD = $(TARGET)$(VERSION)
clean:
cd examples/milner; make clean
cd examples/cmilner; make clean
cd examples/queen; make clean
cd examples/adder; make clean
cd examples/fdd; make clean
cd examples/calculator; make clean
cd examples/solitare; make clean
cd examples/money; make clean
cd examples/internal; make clean
cd src; make clean
cd doc; make clean
rm -f *~
rm -f $(TARGET).tar.gz
rm -f $(RD).tar.gz
examples: dummy
cd examples/milner; make
cd examples/cmilner; make
cd examples/queen; make
cd examples/adder; make
cd examples/fdd; make
cd examples/calculator; make
cd examples/solitare; make
cd examples/money; make
dummy:
backup: clean
tar -cvf $(TARGET).tar *
gzip $(TARGET).tar
rel: clean docs
cd src; make depend
mkdir $(RD)
mkdir $(RD)/src
mkdir $(RD)/doc
mkdir $(RD)/examples
cp config makefile README CHANGES $(RD)
./copysource $(RD)/src
cp src/depend.inf src/makefile $(RD)/src
cp doc/buddy.ps $(RD)/doc
cp doc/bddnotes.ps $(RD)/doc
cp doc/tech.txt $(RD)/doc
echo "clean:" > $(RD)/doc/makefile
mkdir $(RD)/examples/milner
cp examples/milner/* $(RD)/examples/milner
mkdir $(RD)/examples/cmilner
cp examples/cmilner/* $(RD)/examples/cmilner
mkdir $(RD)/examples/adder
cp examples/adder/* $(RD)/examples/adder
mkdir $(RD)/examples/queen
cp examples/queen/* $(RD)/examples/queen
mkdir $(RD)/examples/fdd
cp examples/fdd/* $(RD)/examples/fdd
mkdir $(RD)/examples/calculator
mkdir $(RD)/examples/calculator/examples
cp -R examples/calculator/* $(RD)/examples/calculator
mkdir $(RD)/examples/solitare
cp examples/solitare/* $(RD)/examples/solitare
mkdir $(RD)/examples/money
cp examples/money/* $(RD)/examples/money
mkdir $(RD)/examples/internal
cp examples/internal/* $(RD)/examples/internal
tar -cvf $(TARGET)$(VERSION).tar $(RD)/*
gzip $(TARGET)$(VERSION).tar
rm -fr $(RD)
@cat RELEASE

6
buddy/src/.cvsignore Normal file
View file

@ -0,0 +1,6 @@
*.lo
*.la
.libs
.deps
Makefile.in
Makefile

29
buddy/src/Makefile.am Normal file
View file

@ -0,0 +1,29 @@
include_HEADERS = bdd.h fdd.h bvec.h
lib_LTLIBRARIES = libbdd.la
libbdd_la_SOURCES = \
bddio.c \
bddop.c \
bddtree.h \
bvec.c \
cache.c \
cache.h \
cppext.cxx \
fdd.c \
imatrix.c \
imatrix.h \
kernel.c \
kernel.h \
pairs.c \
prime.c \
prime.h \
reorder.c \
tree.c
# See the `Updating version info' node of the Libtool manual before
# changing this.
libbdd_la_LDFLAGS = -version-info 0:0:0
check_PROGRAMS = bddtest
bddtest_SOURCES = bddtest.cxx
bddtest_LDADD = ./libbdd.la

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/bdd.h,v 1.1 2003/05/05 10:57:56 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/bdd.h,v 1.2 2003/05/05 13:45:04 aduret Exp $
FILE: bdd.h
DESCR: C,C++ User interface for the BDD package
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/bddio.c,v 1.1 2003/05/05 10:57:56 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/bddio.c,v 1.2 2003/05/05 13:45:04 aduret Exp $
FILE: bddio.c
DESCR: File I/O routines for BDD package
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/bddop.c,v 1.1 2003/05/05 10:57:56 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/bddop.c,v 1.2 2003/05/05 13:45:04 aduret Exp $
FILE: bddop.c
DESCR: BDD operators
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/bddtree.h,v 1.1 2003/05/05 10:57:56 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/bddtree.h,v 1.2 2003/05/05 13:45:05 aduret Exp $
FILE: tree.h
DESCR: Trees for BDD variables
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/bvec.c,v 1.1 2003/05/05 10:57:56 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/bvec.c,v 1.2 2003/05/05 13:45:05 aduret Exp $
FILE: bvec.c
DESCR: Boolean vector arithmetics using BDDs
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/bvec.h,v 1.1 2003/05/05 10:57:56 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/bvec.h,v 1.2 2003/05/05 13:45:05 aduret Exp $
FILE: bvec.h
DESCR: Boolean (BDD) vector handling
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/cache.c,v 1.1 2003/05/05 10:57:56 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/cache.c,v 1.2 2003/05/05 13:45:05 aduret Exp $
FILE: cache.c
DESCR: Cache class for caching apply/exist etc. results in BDD package
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/cache.h,v 1.1 2003/05/05 10:57:56 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/cache.h,v 1.2 2003/05/05 13:45:05 aduret Exp $
FILE: cache.h
DESCR: Cache class for caching apply/exist etc. results
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/cppext.cxx,v 1.1 2003/05/05 10:57:56 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/cppext.cxx,v 1.2 2003/05/05 13:45:06 aduret Exp $
FILE: cppext.cxx
DESCR: C++ extension of BDD package
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/fdd.c,v 1.1 2003/05/05 10:57:56 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/fdd.c,v 1.2 2003/05/05 13:45:06 aduret Exp $
FILE: fdd.c
DESCR: Finite domain extensions to BDD package
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/fdd.h,v 1.1 2003/05/05 10:57:56 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/fdd.h,v 1.2 2003/05/05 13:45:07 aduret Exp $
FILE: fdd.h
DESCR: Finite domain data with BDDs
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/kernel.c,v 1.1 2003/05/05 10:57:57 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/kernel.c,v 1.2 2003/05/05 13:45:07 aduret Exp $
FILE: kernel.c
DESCR: implements the bdd kernel functions.
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/kernel.h,v 1.1 2003/05/05 10:57:57 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/kernel.h,v 1.2 2003/05/05 13:45:07 aduret Exp $
FILE: kernel.h
DESCR: Kernel specific definitions for BDD package
AUTH: Jorn Lind
@ -167,7 +167,12 @@ extern bddCacheStat bddcachestats;
#define BDDZERO 0
#ifndef CLOCKS_PER_SEC
#define CLOCKS_PER_SEC DEFAULT_CLOCK
/* Pass `CPPFLAGS=-DDEFAULT_CLOCK=1000' as an argument to ./configure
to override this setting. */
# ifndef DEFAULT_CLOCK
# define DEFAULT_CLOCK 60
# endif
# define CLOCKS_PER_SEC DEFAULT_CLOCK
#endif
#define DEFAULTMAXNODEINC 50000

View file

@ -1,49 +0,0 @@
# ==============================================================
# Makefile for BDD source
# - Do not touch
# ==============================================================
# --- full object list
OBJ = bddio.o bddop.o bvec.o cache.o cppext.o fdd.o imatrix.o kernel.o \
pairs.o prime.o reorder.o tree.o
CFILES = bddio.c bddop.c bvec.c cache.c fdd.c imatrix.c kernel.c \
pairs.c prime.c reorder.c tree.c
CCFILES = cppext.cxx
include ../config
# --------------------------------------------------------------
# Code generation
# --------------------------------------------------------------
.SUFFIXES: .cxx .c
.cxx.o:
$(CPP) $(CFLAGS) $(DFLAGS) -c $<
.c.o:
$(CC) $(CFLAGS) $(DFLAGS) -c $<
# --------------------------------------------------------------
# The primary targets.
# --------------------------------------------------------------
libbdd.a: $(OBJ) ../config
ar r libbdd.a $(OBJ)
ranlib libbdd.a
clean:
rm -f lib$(TARGET).a
rm -f *.o core *~
rm -f libbdd.a
rm -f bddtest
depend:
gcc -MM $(CFLAGS) $(DFLAGS) $(CFILES) > depend.inf
g++ -MM $(CFLAGS) $(DFLAGS) $(CCFILES) >> depend.inf
bddtest: libbdd.a bddtest.cxx ../config
$(CPP) $(CFLAGS) $(DFLAGS) bddtest.cxx -o bddtest -L. -lbdd
###
include depend.inf

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/pairs.c,v 1.1 2003/05/05 10:57:57 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/pairs.c,v 1.2 2003/05/05 13:45:08 aduret Exp $
FILE: pairs.c
DESCR: Pair management for BDD package.
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/prime.c,v 1.1 2003/05/05 10:57:57 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/prime.c,v 1.2 2003/05/05 13:45:08 aduret Exp $
FILE: prime.c
DESCR: Prime number calculations
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/prime.h,v 1.1 2003/05/05 10:57:57 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/prime.h,v 1.2 2003/05/05 13:45:08 aduret Exp $
FILE: prime.c
DESCR: Prime number calculations
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/reorder.c,v 1.1 2003/05/05 10:57:57 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/reorder.c,v 1.2 2003/05/05 13:45:08 aduret Exp $
FILE: reorder.c
DESCR: BDD reordering functions
AUTH: Jorn Lind

View file

@ -28,7 +28,7 @@
========================================================================*/
/*************************************************************************
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/tree.c,v 1.1 2003/05/05 10:57:57 aduret Exp $
$Header: /Volumes/CVS/repository/spot/spot/buddy/src/tree.c,v 1.2 2003/05/05 13:45:08 aduret Exp $
FILE: tree.c
DESCR: Trees for BDD variables
AUTH: Jorn Lind